How to debug in jupyter?

Hello everyone, just to clarify, what I mean is how to debug jupyter itself, not how to debug under code mode in jupyter notebook. I want to modify jupyter a bit, but can’t find how to debug when I change something. What I have done currently is to print everything, which is not efficient.

Any help would be nice, thanks in advance ~

1 Like

If you refer to modifying the Python code, it might be a good idea to start the notebook with the debug flag:

jupyter notebook --debug

which is a bit step up from using a print. I would also try using pdb/ipdb, but I don’t have experience here and do not know if it would work with notebook; I guess it depends on the part of the code you want to modify. What are you trying to achieve in general?