-
Notifications
You must be signed in to change notification settings - Fork 12.8k
electron_node tsserver.js using >100 CPU #38329
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
Comments
(Experimental duplicate detection)
|
@nickofthyme seeing the same thing and I've asked to reopen microsoft/vscode#96255 |
@nickofthyme Was the perf log information collected when using the TypeScript nightly extension? Can you confirm the active TypeScript version by first opening a TS file and then running |
@mjbvz I don't recall, but I'm pretty sure that was using code --status output
|
@nickofthyme Try checking 'TypeScript: Disable Automatic Type Acquisition' in the settings. That seems to have helped, for me at least. |
@nickofthyme I saw similar behaviour in a project of mine (nuxt) where I had a .js file present (it was some server middleware) in a .ts application. After excluding the folder in my tsconfig.json, the cpu issues resolved. |
@njprrogers what do you mean by present? You experienced this with any |
Having similar issue - vs code takes up to 90% CPU, any updates on solution?
Problems appears both on standard and insiders versions. |
EDIT:
worked for me. I'm setting up a new machine, don't have many additional extension installed yet, workspace is large (many directories and files etc) |
EDIT: After some digging, I stumbled upon this issue #39284. After removing Ramda from my dependencies, the performance issues went away instantly. I'm experiencing this as well, on both general release and insiders version. I've tried all suggested solutions, including disabling automatic type acquisition, running without extensions, using the nightly TS extension, etc. electron_node tsserver.js runs at around 100 CPU for 30 seconds - 1 minute on every minor change before eventually providing intellisense, rendering VSCode pretty much unusable for rapid Typescript development. It's only impacting one project (which isn't huge aside from a fair amount of dependencies, which I've excluded in my tsconfig). If I start a new project everything seems to work just fine.
|
@RyanCavanaugh What info is needed? @danbergelt Thanks for the tip! I am not using
|
Is this issue resolved or no one except me is facing this? I have the same issue, and it started all of a sudden, because during last year VSCode was running very smoothly, with no delays or errors at all, and yesterday it blocked the whole intellisense, autocomplete, imports, everything, it's just stuck in loading state and I can see in that Really don't know what to do, I'm on M1 Mac, project is React Native, Typescript, I have only two extensions (Eslint and Prettier), but even without them I get the same issue. Any advices/suggestions will be appreciated a lot.. |
@brascene it comes and goes. Nothing I have done fixes it for good. TS4 was supposed to help but I haven't see any impact good or bad. Eslint seems to be a common denominator not sure if it's related. |
Can the VSCode or TypeScript Team please put some priority into this issue which is open since 3 years? |
Same issue. Laptop fans are constantly humming. Please look into this. One thing that helps momentarily is restarting the ts server |
I commented here a while back, and what I figured out was that it wasn't an issue with VSCode version or some extension, I had a circular dependency mistake in my types. |
This issue hadn't been updated in more than 2 years; it's pretty unlikely that it's still the same bug, and even so, we really need system info and a reproduction that can be used to diagnose the problem, which has so far not been provided, hence the "Needs More Info" label. Pinging us isn't going to help us figure out the problem if you also don't provide us with new info. |
What info specifically? I'm not a VSCode or extension developer. If you let me know what log files etc to share, that'd be helpful. Thanks! |
Do you have a project that we can open and diagnose? Can you provide logs via https://github.com/microsoft/TypeScript/wiki/Getting-logs-from-TS-Server-in-VS-Code ? |
I haven't seen this issue in a long time working daily on the same project that caused me to open this issue in the first place. I'll keep it open as others are interacting with it but if that falls off you can close it. |
@ameeli I think they are requesting more than just logs. Sounds like they want a repo they can run to troubleshoot the problem. The repro should trigger the issue with all extensions disabled. |
@ameeli the log you provided is too small that iit doesnt have any information that can be used for investigation. Please provide repro and full log to be able to investigate this |
Issue Type: Bug
Within the last week I have been struggling with vscode/typescript using upwards of 100% CPU. This leads to 10-30 second delays for intellisense for trivial changes.
The main culprit appears to be
electron_node tsserver.js
.I've seen a few similar issues but none seem to get the to root of the issue, so apologies if this is a duplicate. This looks similar to microsoft/vscode#96255 but I am experiencing this issue with all extensions disabled.
I first notice the issue using
typescript@3.8.3
. Then I tried using the nightly build per suggestion here #34401 (comment). This worked for a day but then the issues resurfaced.Any help debugging this would be greatly appreciated.
output from
code --status
after simple code change.VS Code version: Code 1.44.2 (ff915844119ce9485abfe8aa9076ec76b5300ddd, 2020-04-16T17:07:18.473Z)
OS version: Darwin x64 19.4.0
System Info
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
metal: disabled_off
multiple_raster_threads: enabled_on
oop_rasterization: disabled_off
protected_video_decode: unavailable_off
rasterization: enabled
skia_renderer: disabled_off_ok
video_decode: enabled
viz_display_compositor: enabled_on
viz_hit_test_surface_layer: disabled_off_ok
webgl: enabled
webgl2: enabled
The text was updated successfully, but these errors were encountered: