Python pdb bug, followed by bug in bugs.python.org
donaldcallen at gmail.com
donaldcallen at gmail.com
Thu Apr 11 10:56:06 EDT 2013
> > Suggestions?
>
>
>
> Post the 10-line program here, so others can verify whether it is a bug.
#! /usr/bin/env python3
import pdb
def foo(message):
print(message)
pdb.set_trace()
foo('first call')
foo('second call')
Stick this in an file with execute permission and run it. At the first breakpoint, the backtrace will be correct. Continue. At the second breakpoint, a backtrace will show the foo('first call') on the stack when, in fact, the call came from foo('second call'), as verified by the printed message.
More information about the Python-list
mailing list