Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
IPython debugger. This is a slightly changed ipdb code.
# This is a slightly changed ipdb ( code.
# Shell creation was moved to the set_trace function, because the issue
# with standart unittest module. Now it is usable.
import sys
from IPython.Debugger import Pdb
from IPython import ipapi
from IPython.Shell import IPShell
def set_trace():
shell = IPShell(argv=[])
ip = ipapi.get()
except ImportError:
from pdb import set_trace
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment