Skip to content

Instantly share code, notes, and snippets.

@awesomebytes
Last active August 24, 2020 04:28
Show Gist options
  • Save awesomebytes/20dee3a2bad06f8d2dd304e52e472903 to your computer and use it in GitHub Desktop.
Save awesomebytes/20dee3a2bad06f8d2dd304e52e472903 to your computer and use it in GitHub Desktop.
Drop into interactive console python debugging

To drop into a Python interactive console at some point in your code

import pdb; pdb.set_trace()

And you'll have access to all objects and stuff.

To drop into an iPython interactive console

# sudo apt-get install libncurses5-dev
# sudo pip install --upgrade ipdb ipython readline
import ipdb; ipdb.set_trace()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment