VS unresponsive with big python project

Jul 25, 2012 at 1:02 PM

I tried to create a python project with all our existing python code (about 2500 files) and it takes more than 2 minutes to load!  And when loaded, VS is completely unusable.  For example, if I type something, the characters will appear at a rate of about one per second.

Is it a known issue with big projects?  I created the project with the "Project from existing code..." option in the File/New menu.



Jul 25, 2012 at 3:31 PM

It sounds like our analysis may be taking a long time (not a surprise - that's a big project!), but I would not have expected it to interfere with typing once everything is loaded.

Could you provide some information about your PC specifications (CPU, #cores, RAM, disk/SSD) and maybe check Task Manager to see if something is obviously consuming a lot of CPU time or memory?

I have occasionally seen some intermittent performance issues when there are errors in the source file - are we reporting any errors in the file you are editing?

Jul 25, 2012 at 3:52 PM

My PC specs:

Intel Xeon W3565 (4 cores, 8 threads)
Unknown HDD (not SSD)

The loading time is actually a lot more than 2 minutes, it takes 7 minutes!  During the loading, devenv.exe takes 12-13% CPU (one thread).  When loaded, it drops down to normal CPU usage, but as soon as I do something, like typing, it goes back to 12-13% for a couple of seconds.  No other processes are using the CPU significantly.

Jul 25, 2012 at 4:17 PM

There are some errors and warnings (6 errors and 113 warning), but they are not in the source file I'm editing.  I tried to remove all the files causing these errors and warnings and VS was still struggling.

Jul 25, 2012 at 6:12 PM

I've obtained a very large project (14,000 files) and can absolutely reproduce the slow loading. My early view is that a few validation functions are O(n^2) or higher with project size, but we should be able to improve these for the next release.

Right now, I haven't managed to finish loading the project, so I can't verify the low responsiveness yet. I am profiling everything and I'm sure the hot spots will be easily fixed. An immediate workaround is unlikely, but we should be able to include any fixes in an upcoming release.

Jul 25, 2012 at 6:21 PM

Thank you for your fast reply!  Do you think that if I split the files in different projects, for example 10 projects of 250 files, the responsiveness will be better?  Is your processing per project or as whole for the solution?

Jul 25, 2012 at 6:37 PM

That will certainly help with load times, though I have no idea whether the responsiveness will be affected yet. If you try it and let me know whether it improves, that will help track down what's causing the issues.

May 22, 2013 at 4:26 PM
I, too, am experiencing this problem, here is the version info:

Microsoft Visual Studio Premium 2012
Version 11.0.51106.01 Update 1
Microsoft .NET Framework
Version 4.5.50709

Installed Version: Premium

Microsoft Python Tools for Visual Studio 2.0.60306.0

In addition to loading a project with a lot files, if I include a "Search Path" for my project to a directory that has a large number of .py files then the same issue occurs.

Is there any update to this issue?

Thank you,