-
Notifications
You must be signed in to change notification settings - Fork 357
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
High cpu/memory [please comment with details] #44
Comments
My detail report of this (or related) issue.specs: using NTVS 1.0, win8.1 x64, 32gb ram, intel 4core cpu (3.2ghz). Visual Studio 2013, Typescript 1.4 problematic packages: browserify + tsify (tsify seems most likely culprit). This is a typescript project/use. symptoms: when having NPM packages browserify and tsify installed on a project, and then doing a "project scope" change (example: adding a new file) visual studio is unresponsive for large chunks of time (perhaps 2 minutes). Please note that CPU and Memory is NOT highly used. the VS process is unresponsive. removing these two packages (browserify and tsify) causes the issue to go away. I think the issue is due to the large number of dependencies in these projects, and NTVS explodes when trying to process them. Not a problem: Things I did not try:
my solutionuninstall browserify and tsify modules. |
I am in the process of trying to repro this issue. However, after I installed browserify (version 10.0.0), I was not able to successfully install tsify (version 0.8.1). tsify@0.8.1 has a dependency on browserify@6.x || 7.x || 8.x || 9.x. So it failed to install because I had browserfify@10.0.0. Did you see this on your end? If not, which version of browserify did you install? Thanks. |
sorry i ended up removing browserify and tsify, so I don't remember what versions I had. still getting good performance and have not seen this issue since uninstalling them. |
x64 win7 sp1. vs 2013 ultimate.
|
Add just the ''web-component-tester" dev dependency. I do not have Resharper NTVS Tools 1.1 |
After creating a new Node.js blank console application project and installing multiple modules as dev dependencies, CPU usage spiked. Upon inspection, multiple instances of node.exe were running with the description "Evented I/O for V8 JavaScript" and the following command: "C:\Program Files\nodejs\node.exe" "C:\Program Files\nodejs.\node_modules\npm\bin\npm-cli.js" ls --silent -g The solution explorer would also constantly collapse the list of global and dev packages. This occurred with intellisense enabled and disabled. I began removing packages starting with global packages to troubleshoot the problem. After uninstalling all global packages, the issue resolved itself. The issue did NOT return even after re-installing all global packages. Global packages were:
Dev dependencies were:
One interesting item of note is that I also received a warning about the 260 character limit which was NOT resolved with dedupe. This situation has not changed since several module files are still long past the 260 character limit, but the issue is still resolved. ReSharper NOT installed. IDE Info: Microsoft Visual Studio Premium 2013 Installed Version: Premium Node.js Tools 1.0.30324.01 Node.js Tools - Profiling 1.0.30324.01 |
Regarding high CPU usage: When running VS with NodeJS project opened under debugger, the constant flow of events in the Output Log. This flow is never stopped. CPU usage ~22%.
|
@kant2002 can you try adding gulp-imagemin to the ignored directories for analysis? Also you should be able to see similar info printed in the diagnostic window (much easier than spinning up the debugger every time) When you say it didn't complete, how long did you wait? |
Actualy it may complete after a while. I just tired waiting ~5 min.
And that's on Medium level of Intellisense (depth analysis = 2) @mousetraps Thanks for useful tip, maybe if I know about it, I will never try to resolve that issue in the first place 😄 but right now I better fix as much as I can. |
Hi, I tried to import an existing meanjs.org project. It froze for 10 minutes, 50% cpu, more than 1gb RAM. Then the filetree opened. VS 2015 RC / Win 8.1 / 16GB RAM / NTVS 1.1b |
I was having terrible memory usage problems (VS would just climb until around 2.3GB) using NTVS v1.0.30428.03 with VS2015. However, after disabling Intellisense (and Save to Disk option which consequently removes any existing files) the issue completely disappears, memory usage now fluctuates between 200-300MB which is about expected. |
My dev environment setup is, from what was listed, the same as @syagev I disabled Intellisense, and disabled Save to Disk. The issue went away. Obviously, I would like to have Intellisense enabled. I'll post details on my attempt to ignore specific directories. |
I added node_modules & public/lib to the AnalysisIgnoredDirectories property group. Then I re-enabled Intellisense, and Save to Disk. The issue came back, and my cpu usage spiked, and VS's memory usage climbed to 3GB before crashing. |
NTVS Commit: 8bacc39 Two small Express 4 projects First (14 files):
Second project
Now to more interested part:
and result of
|
I documented my journey with AnalysisIgnoredDirectories in #316 |
Shooting the moon here, but I'm getting the sense (on my machine at least) that this is somehow caused by some sort of race between NTVS, Dropbox, and maybe also a shell extension (TortoiseGit). After suffering from this on random (but quite frequent) occasions, I started making sure I use NTVS, TortoiseGit's shell extension, and Dropbox exclusively. This is relevant of course just because both dropbox and TortoiseGit are watching the directory where the Node.js project is. I'm posting this comment after a few successful weeks without the symptoms. |
I had a similar sequence of events like @waynebloss. I installed VS 2015 Community Edition today and created a NodeJS project. Lots of CPU usage and disabling all of Intellisense fixed the issue, however ignoring specific node_modules packages did not. After fiddling around with it for about a half hour the issue finally corrected itself and I do not see any high CPU usage for this project anymore even when I close and re-open it. |
Tedious module also causes a high cpu/memory usage. |
Discover new issue related to high CPU #415 |
+1 VS2015 Enterprise, NodeJS Tools 1.1. Project with high amount of JS files. Analysis takes 3:41. VS UI would periodically hang every 15-30 seconds, pretty awful. Disabled node.js intellisense and save to disk and issues went away. |
FYI, I have a workaround: put most of my files in a "library" project (a typescript web project) so that node_modules will not be parsed. then have a small "app" project that contains my server.ts file and some app-specific .ts files. This is a NTVS project so it can be run and debugged via visual studio. This resolves most of my edit-time performance problems. Also FYI, unfortunately the adding |
@Oceanswave @jasonswearingen can you please share your findings from the steps recommended in #44 (comment)? |
@mousetraps My original steps/findings are described at the top of this thread. Making my "entrypoint" a minimal A related problem I discovered after doing that workaround: If my _edit_: also I'm not 100% certain but I think some of my global modules may have been contributing to the issue. for example the _edit2_: It would be nice if there was a way to tell NTVS to totally ignore node_modules. As I'm using Typescript I don't need node_modules to be parsed at all. I just need the debugger features of NTVS _edit3_: duh, i should try disabling NTVS intellisence... will try that. |
Try disabling the cache file ( |
i disabled the intelisense and my problems are resolved. since I don't use the javascript intellisence, I didn't even notice anything "different" in the experience.... except it's faster and no crashing! |
Same issue, Metalsmith project, Win10, VS2015, inside a Hyper-V VM with 4gb max allotted. Disabling Intellisense fixed it. Should note, it was doing it for both a blank project and a project from existing files. |
I'd wager life would be much easier for everyone if you change to opt-in rather than opt-out for analysis. Trying to use VS with my project was painful. Slow, near constant 30% CPU usage, Halting on close. After I ignored all the big folders (and my dist output), problem went away...
|
I have also had a problem with OutOfMemoryException and issue went away after doing this: https://github.com/Microsoft/nodejstools/wiki/Projects#ignoring-directories-for-analysis Essentially the nsproj file needs the node_modules, same as @MeirionHughes wrote. |
This thread is getting a little unmanageable. Closing, but please file a new issue if you're still running into problems with the latest bits. We're currently working on integrating Salsa for our IntelliSense experience going forward (behind the ES6 Preview flag) which should help address some of these perf issues. So keep an eye out for the next VS 2015 Update and NTVS releases. |
Multiple people have been running into this issue in varying forms, so this is a catch-all issue we can direct people to until we have narrowed down the root cause (after which we will spawn off a separate issue).
If you're encountering high memory/cpu, please share some details about your project in the comments below to help us get to the bottom of it. In particular...
Please comment with the following details for the quickest response/fix
Known workarounds
This description will be updated as we learn more information. Resolving this issue is high priority, so thanks in advance for the help!
[copied from https://nodejstools.codeplex.com/workitem/1903]
The text was updated successfully, but these errors were encountered: