i am using the python shell to try to do debugging
i set a breakpoint
i did:
>>> import pdb
>>> import mymodule
>>> pdb.run('mymodule.test()')
but it is just running my program without stopping at the breakpoint!
what am i donig wrong?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
How did you set a breakpoint? Try adding the line in your code:
and then run it. If you’re in the pdb shell, then “break foo.py:45” will break on line 45 of file foo.py.
Here are some useful commands:
Check the full list by typing ‘h’. And “help X” will give you help on command X. Also, see this tutorial: