On Tue, Apr 12, 2011 at 11:15 AM, Djoume Salvetti email@example.com wrote: ..
When calling pdb.set_trace() from within a function, it seems to be impossible to rebind any local variables:
Works for me (using latest HG clone):
$ cat test.py gv = 1
def f(): lv = 1 import pdb; pdb.set_trace()
if __name__ == '__main__': f() $ ./python.exe test.py --Return--
-> import pdb; pdb.set_trace() (Pdb) lv = 2 (Pdb) print lv 2
Please don't use paste services when posting on python-dev. Postings to this list are archived much longer than links to paste services remain valid.
I couldn't find anything in the documentation about this, should I report a bug?
If you find specific versions that are affected by this bug, please report it at bugs.python.org.