Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to quit an iPython notebook debug session?

I am using iPython notebook, with the %%debug command. My code performs a loop, in which I set some break point. Now I can't seem to stop the loop with 'CTRL+C' (works in the regular ipython).

For example, let's say I have some loop with an ipdb.set_trace() inside. Now if I hit the 'C' key the loop continues to the ipdb.set_trace(), with no option from the user the exit the loop with 'CTRL+D/C'.

How can I exit such a loop?

like image 772
aviyaron Avatar asked Mar 24 '16 14:03

aviyaron


1 Answers

You can write exit() to quit debug mode.

like image 168
UMY Avatar answered Sep 28 '22 02:09

UMY