pycharm debugger slow due to "collecting data"

Answered
Just starting out with pycharm and I like it a lot so far.  One problem though is that when debugging, the debugger seems to hang for many seconds when I step over/into/out with "collecting data" in the "variables" window.  It really hurts my productivity if I have to wait multiple seconds for each step over/into/out.

Anyone know what can cause this?  Not sure where to start looking.  I googled it of course but didn't come up with much.

specs: pycharm 3.4.1 and python 2.7.6.  Running pycharm on a CentOS VM, windows host.

thanks,

Jesse
1
4 comments
Avatar
Permanently deleted user

I know you posted this over four years ago, but in my experience, this can be resolved by collapsing any of the variables' sublists (or whatever you call them) so that the "Variables" window has to display as little as possible.  If all the variables are already completely collapsed, this may be a good time to consider isolating the variables into their own classes to manage them all.

0

Hi! There's a new special option in 2018.2 EAP for variable loading policy. "On-demand" should do the trick.

0
Avatar
Permanently deleted user

I know this is an old post, but this seems to keep popping up/going away without much reason for me. The same code will work with 0 pause due to 'collecting data' and then on a subsequent run I get the dreaded 'collecting data...' leading to 'unable to display frame variables' even with 'on demand' set (and a restart of pycharm). The only thing that seems to help is restarting the machine. I think there is more going on here than a lot of variables being loaded. Some quick stats for me: python 3.8.5 (and previous versions), ubuntu 20.04 (and 18.04), PyCharm professional 2021.1 (and basically every version for the last year), multiple dev machines set up independently of one another. This happens more if the code involves pytorch, but isn't exclusive to it. Are there other debugging steps to look into here?

0

Hello Susan

 

Could you please submit a request at https://youtrack.jetbrains.com/issues/PY  so we will investigate this?

Please upload your logs folder zipped from ***Help | Collect logs and Diagnostic Data*** and a simplified project example. 

0

Please sign in to leave a comment.