How long should the Debugger take to initialize? (slow)
Hi. How many seconds should the debugger take to initialize--,for a simple 3-4 line python script with a single (pprint) import?
In my case, it takes about 5 seconds...is this normal?
PyCharm 2021.2.2 (Professional Edition), Build #PY-212.5284.44, built on September 14, 2021
GVENT (Checked), Drop into Debugger on Failed Test (Unchecked), Memory Setttings (4048)
Windows 10 Pro, 32 gigs RAM, Intel(R) Core(TM) i7-9700 CPU @ 3.00GHz 3.00 GHz
Thanks
Running a Conda Virtual Environment (WSL2 Ubuntu) on Windows 10
Thanks
Please sign in to leave a comment.
Hi,
In my case, with conda enviroment inside WSL, a simple script like:
... is executed with debugger in about one second. Does it take more in your case with the same script?
that above script took about 9 seconds to initialize. The debugger does initially print out 40-50 stub and remote_sources locations
Does the same issue happen if you debug with a local interpreter instead?
Using a Windows version of Anaconda (not the wsl2 ubuntu anaconda version I normally use), it took ~5 second to initialize. Loads in half the time, but still very slow. Any help is appreciated.
Could you please submit a support ticket at https://intellij-support.jetbrains.com/hc/en-us/?pycharm and mention it's for Andrey Resler? You can attach the debug output there, it will be private.
Another thing - does Run works faster (instead of Debug)? Let me know in the ticket as well.
Thanks.
Hi, was there any progress made on resolving this issue of a slow debugger? I'm having a similar problem where it takes ~3.5 seconds to run the code below but takes between ~17-30 seconds to debug (depending on how many packages are installed in the conda environment I'm using). I am running conda environments (WSL2 Ubuntu) on Windows 11 and can provide additional information if it'd be helpful!
Ah, it turns out that WSL2 has poor performance across OS (e.g. Linux and Windows) file systems (see https://learn.microsoft.com/en-us/windows/wsl/compare-versions). I was running Pycharm in Windows but running code and using a conda interpreter that was located in WSL2.
I tried using WSL1 instead, which significantly reduced the time to debug. However, WSL 1 didn't seem to natively support GUI / graphics (I tried a few tutorials but struggled to get it working). In the end, I went back to WSL2 but this I simply ran Pycharm within WSL2, which allowed for both quick debugging but also decent graphics support.