Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
TraitError while setting a python debbugger #1136
While setting an ipython brake-point we get an exception.
The brake-point set is
The error does not occur with version 1.3a1
To quote an email I sent another colleague:
The code in question is digging into undocumented internals of the
try: # Event is a function returning an instance of _Event... save_flag = Instance(threading._Event, allow_none=True) except AttributeError: # ...until Python 3.3, when it's a class. save_flag = Instance(threading.Event, allow_none=True)
gevent's monkey-patch currently only gets the public interface.
I have a compatibility fix for this merged into master in #1137
Other than that, I can suggest two options:
from IPython.terminal.debugger import set_trace; set_trace() ## DEBUG ##
Change that to
from gevent.event import Event; import threading; threading._Event = Event; from IPython.terminal.debugger import set_trace; set_trace() ## DEBUG ##