5

I have been running into issues when using the debugger within Jupyter Notebook, Specifically this command:

from IPython.core.debugger import Tracer
Tracer()() #this one triggers the debugger

Whenever I use Tracer()() the inline debugger shows as expected, but once I enter any command in the field : n(ext), s(tep), etc. I jump to the line:

finally:
  # Reset our crash handler in place
  sys.excepthook = old_excepthook

Here is an image of the issue and the code that was attempted to be debugged (The exact code is not relevant as I am able to reproduce the issue in other notebooks).

Jupyter Notebook Tracer()() Output

I am working on a mac running OSX El Capitan, and using Anaconda for python 2.7. Here are some details about my current setup obtained by running:

conda info --all (from root env)

System Information via: conda info --all from (root) env

Note, I have tried several different debugging options: pdb, ipdb, and Tracer() but ran into separate issues with each. Tracer() seems like the standard option at this time, per the Stackoverflow question Using ipdb to Debug Python Code in Jupyter.

Additionally, I have been able to replicate this issue on my Dell computer running Windows 7.

Any help would be greatly appreciated!

Community
  • 1
  • 1
joshf
  • 251
  • 1
  • 3
  • 6
  • I've the exact same problem, have you solved this issue yet? – Svenno Nito Oct 12 '17 at 12:01
  • Possible duplicate of ['n' in pdb moves me inside of the pdb.set\_trace() method](https://stackoverflow.com/questions/32529638/n-in-pdb-moves-me-inside-of-the-pdb-set-trace-method) – ftiaronsem May 01 '18 at 11:58
  • Also see https://stackoverflow.com/questions/46495269/debuggers-not-acting-properly-on-jupyter-notebooks – ftiaronsem May 01 '18 at 11:59

0 Answers0