[issue9274] code.InteractiveInterpreter fails to change locals when invoked in a function

2019-04-27 Thread Mark Lawrence
Change by Mark Lawrence : -- nosy: -BreamoreBoy ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue9274] code.InteractiveInterpreter fails to change locals when invoked in a function

2014-10-01 Thread Mark Lawrence
Mark Lawrence added the comment: @Eric can you provide a doc patch for this? -- nosy: +BreamoreBoy versions: +Python 3.4, Python 3.5 -Python 2.6, Python 3.1, Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9274

[issue9274] code.InteractiveInterpreter fails to change locals when invoked in a function

2010-07-16 Thread Eric Promislow
New submission from Eric Promislow er...@activestate.com: Similar to bug http://bugs.python.org/issue5215 which found a workaround in pdb. Here I want to use code.InteractiveInterpreter to modify code interactively (see Komodo bug http://bugs.activestate.com/show_bug.cgi?id=87405 ) I can do

[issue9274] code.InteractiveInterpreter fails to change locals when invoked in a function

2010-07-16 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Apparently I can't even see the activestate bug without creating an account there, so posting a link to it is not helpful. Please post more details about how you are calling InteractiveInterpreter and what the problem is that you are

[issue9274] code.InteractiveInterpreter fails to change locals when invoked in a function

2010-07-16 Thread Eric Promislow
Eric Promislow er...@activestate.com added the comment: I've modified the bug status so anyone can read it. You don't need an account to read ActiveState bugs, only to add or comment on one. Please note that I closed bug http://bugs.activestate.com/show_bug.cgi?id=87405, as we're now writing

[issue9274] code.InteractiveInterpreter fails to change locals when invoked in a function

2010-07-16 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: locals() does not give you a copy of the locals dictionary that you can modify and expect the values to affect the actual locals they were copied from. This is documented: http://docs.python.org/library/functions.html#locals You would

[issue9274] code.InteractiveInterpreter fails to change locals when invoked in a function

2010-07-16 Thread Eric Promislow
Eric Promislow er...@activestate.com added the comment: Thanks for the response. Note that our use case *is* to implement Python-console functionality, but sometimes we do this in the context of a currently running Python program, inside a function. That's why I wrote the repro that way. Using

[issue9274] code.InteractiveInterpreter fails to change locals when invoked in a function

2010-07-16 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Well, you could discuss that possibility on python-dev, I suppose. As long as you don't need the changes to persist outside of the debugging loop, you can use InteractiveInterpreter as designed and keep passing it the same (modified)

[issue9274] code.InteractiveInterpreter fails to change locals when invoked in a function

2010-07-16 Thread Eric Promislow
Eric Promislow er...@activestate.com added the comment: David, that won't work for a reason I'll get into in a bit. I would drop the priority of this ... Komodo has a had a Python debugger since late 2000, we only fixed updating variables while debugging (using the variable viewer) yesterday,