question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Endless 100% CPU when search/replace many TS files at once

See original GitHub issue
  • VSCode Version: insiders
  • OS Version: macOS 10.14

Steps to Reproduce:

  1. open the vscode workspace
  2. search for “copyright” in *.ts
  3. replace with “copyright2
  4. run and wait

=> the TS extensions seems to go up to a 100% and stays there without ever recovering.

Full command line:

bpasero 78619 100.1 11.0 6870176 1840020 ?? R 7:14AM 2:13.12 /Applications/Visual Studio Code - Insiders.app/Contents/Frameworks/Code - Insiders Helper.app/Contents/MacOS/Code - Insiders Helper /Applications/Visual Studio Code - Insiders.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js --useInferredProjectPerProjectRoot --enableTelemetry --cancellationPipeName /var/folders/w_/xgfzkgq14jv_ykk2lm0k_h5c0000gn/T/vscode-typescript/tscancellation-43d76d57848697e4dfca.tmp* --locale en --noGetErrOnBackgroundUpdate

Issue Analytics

  • State:open
  • Created 5 years ago
  • Reactions:3
  • Comments:9 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
roblourenscommented, Mar 3, 2021

Here is the old discussion: https://github.com/microsoft/vscode/issues/89300

The impact is bad and surprising to extension developers, it would be great if we could open a model in a lightweight way that doesn’t get broadcast to the world since we know we will immediately close it. But if extensions want to participate in opening and editing and saving then it might also be surprising to not find out about it.

1reaction
pladariacommented, Dec 30, 2020

We have a TS repo with few thousand files, we were getting 100% usage in several cores and the problem was caused by:

"typescript.tsserver.experimental.enableProjectDiagnostics": true,

That was enabled in our workspace config.

This configuration makes the eslint extension go crazy by constantly checking files (doesn’t seem to end). This was barely noticeable on a 16 core machine but puts a 2015 macbook pro on fire.

Hope this helps someone

Read more comments on GitHub >

github_iconTop Results From Across the Web

Constant 100-200% CPU usage when any JS or TS file is ...
Constant 100-200% CPU usage when any JS or TS file is open. ... Once you close the file the CPU goes back down...
Read more >
Modern IDEs are magic. Why are so many coders still using ...
While there are many IDEs on the market, there's no reason to use one if you don't have to use one. It's the...
Read more >
[PC] Extremely high cpu usage :: ENDLESS™ Space 2 ...
Somethings in the game creating too much cpu usage: - Randomly pop up screens. Same popup screen sometimes does not do this. -...
Read more >
Wlj - River Thames Conditions - Environment Agency - GOV.UK
M&g property fund changes, Goldring student centre u of t, Ampt madison, Abhyudaya bank home loan interest rates? Icing for carrot cake thermomix, ......
Read more >
Getting Started with Niagara 4 - LG HVAC
Much of the Niagara software is written in Java, which means that it is platform ... Module .jar files are the mechanism for...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found