Advertisement
NLinker

Debugging the jupyter notebook

Mar 19th, 2018
337
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.26 KB | None | 0 0
  1. from IPython.core.debugger import set_trace
  2.  
  3. def some_fun(x):
  4.     answer = 42
  5. #     import pdb; pdb.set_trace() -- this is ok, but no highlighting, less convenient than IPython.core.debugger
  6.     set_trace()
  7.     answer += x
  8.     return answer
  9.  
  10. some_fun(12)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement