extremely slow debugger

IS there a way to turn off some of the pycharm features w.r.t debugger to make it faster?  We're noticing 10-100x runtime slowdown when running through the debugger - this has to be possible, because running python -m pdb and using pdb.set_trace do not incur any observable speed penalty
5 comments
Comment actions Permalink
Hi, you can start with turning off exception breakpoints. They can add overhead.

https://www.jetbrains.com/pycharm/help/creating-exception-breakpoints.html
1
Comment actions Permalink
Mine is not turnned on, still very slow.  I have the same issue as hugo shi
0
Comment actions Permalink
is there really no solution for this?  we might have to mix Wingware IDE for debugging and pycharm for coding then....  the slowness is a total show stopper
0
Comment actions Permalink
I've found you can side-step it to some degree by using the "Remote Debug" feature. That way you can start your application outside of the debugger (so it's not slow to start), and put a pydevd.settrace in your code to connect to it the same way as you would a pdb.set_trace.

That works okay as long as you do have the ability to edit the source and put that settrace in there before any other breakpoints you need to stop at. And it might well go back to being slow after the settrace, I'm not entirely sure.
0
Comment actions Permalink

Today's 5.1 EAP has some debugger performance improvements. I had a code base where 5.0 took 9.3 seconds to get to a breakpoint. 5.1 takes 8.5 seconds. When I install the pydevd Cython speedups, it goes down to 5.7 seconds. I'm putting up a tweet with a video later today.

Hugo, if you get a chance, can you record a before/after?

0

Please sign in to leave a comment.