-
Notifications
You must be signed in to change notification settings - Fork 12.8k
Auto imports (getExportInfoMap
) extremely slow
#46735
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
/needsMoreInfo Is it reproducible with all extensions disabled? Is this problem consistent across different projects? |
This problem appears when working with node projects |
it's taking a period of time to show suggestions list |
when I disable that built-in Extention, VS Code works normally in the task manager. |
@moataz9 Exactly I'm facing the same problem... : (
|
yes that's it |
Please share an example project that demonstrates the issue |
When I work on a small node project (using less than 4 packages) the suggestions list shown up normally. when I add more packages to use in that project, it leads the suggestions list doesn't appear normally (loading ... for a long period sometimes it take 2 min to show up and VS code in the task manager take more than normally in CPU measure as I mentioned previously ) here are the packages I use in my project {
"dependencies": {
"bcryptjs": "^2.4.3",
"cors": "^2.8.5",
"dotenv": "^10.0.0",
"express": "^4.17.1",
"express-async-errors": "^3.1.1",
"express-rate-limit": "^5.3.0",
"helmet": "^4.6.0",
"http-status-codes": "^2.1.4",
"joi": "^17.4.0",
"jsonwebtoken": "^8.5.1",
"mongoose": "^5.13.2",
"rate-limiter": "^0.2.0",
"swagger-ui-express": "^4.1.6",
"xss-clean": "^0.1.1",
"yamljs": "^0.3.0"
},
"devDependencies": {
"nodemon": "^2.0.9"
}
} |
@moataz9 hyy reinstalled nodejs and vs code worked
|
@ullaskunder3 it doesn't really work for me |
@moataz9 How do I reproduce this issue using that project? |
@mjbvz here is the project repo |
Thanks but what specific steps do I take to reproduce this issue in that project? |
In my opinion, that problem occurred because the extension gathering its data, again and again, every time the VScode activate that extension (the suggestions list, coloring unused variables & functions parameters, ....) |
Please share the specific steps to trigger this issue. I don't see an this problem if I open Also does this reproduce in the latest VS Code insiders build with all extensions disabled? (don't disable the built-in extension) |
@mjbvz yes, it's still reproduced in the latest VS Code insiders build with all extensions disabled. |
here is exactly what happens in my laptop |
Please try collecting the TS Server log for this:
|
here is my tsserver log file |
@ullaskunder3 I try to use it inside another project that doesn't use MongoDB (small node and express app) and unfortunately is still reproduced on my pc |
do I need to exchange any hardware chips |
@moataz9 sir did you changed the typescript version, right now vs code using 4.4.3 & |
|
I have this issue and do not use mongoose. It's been so slow the past couple of months that I've started typing everything out. Not much to contribute but didn't want anyone caught up on mongoose specifically. |
Same issue here. After 10-15min intellisense becomes unbearable and I have to keep restarting the editor. I have a fairly simple file with about 300 lines of code for a Babel plugin using @babel/core, but it eventually becomes slow regardless of the project. I tried both on Linux and Windows and have the same exact issue on both OSs. |
Thanks for the logs @moataz9! From them, I can see where the long requests are happening:
Moving upstream to TS to see if they have any ideas on what may be causing this |
@moataz9 can you try disabling |
@andrewbranch I tried that solution but it doesn't affect the issue |
Related (re: mongoose): |
Also experiencing slow VSCode since 4.5 upgrade. I believe maybe because of https://github.com/Vincit/objection.js/ types? Switching back to 4.4 makes it instant, as usual. |
I'm experiencing the same issue. With I have no idea what's happening under the hood, but these are the two things from the server log that look very slow in 4.52:
Part of TS 4.5.2 server log
|
Ah sorry, I missed the geterr elapsed time coming back as a separate event. |
Here's the minimal repro (basically, only I've found out that this issue is reproducible with |
Hi, I hope I can give some additional helpful info. I maintain a repo with some fairly complex generic types and I can see a huge performance difference in both Also I don't think this is really related to the VSCode plugin, because I use (Neo)Vim and a language client plugin in there to talk to tsserver. The autocompletion with 4.4.4 is there in less than a second while 4.5.2 sometimes takes longer than 5 seconds. (My client just lets it time out then.) Another thing I observed is that the hover comes up fairly quickly, but autocompletion does not. When the repo files are freshly changed both take a really long time to come up. Here is the repo: https://github.com/League-of-Foundry-Developers/foundry-vtt-types 4.4.4
4.5.2
|
@andrewbranch turns out, it's not only about vs code,
TS 4.4.4 extended diagnostics
TS 4.5.2 extended diagnostics
|
getExportInfoMap
) extremely slow
This is excellent repro information @atsikov and @kmoschcau. However, it’s a completely separate issue from the one reported by @moataz9, so I’ve forked your issue to #46948. If you have any further discussion, please continue it there. Let’s keep this issue specific to |
@moataz9 do you still have this issue when you use the latest nightly JS/TS via this extension? The slowness you measured is showing up in a different place than what others mentioned here, but it could actually have the same root cause. We’ve made a lot of performance fixes recently so it’s worth trying this again. |
@andrewbranch no, I don't have this issue anymore. thanks for the great work. |
Issue Type: Performance Issue
trying to use ctrl + space
loading... for a period of time
when I disabled it from builtin extensions
the list is shown as expected
please vs-code team solve that problem because that builtin extension is so essential for us as a web developer
best regards
thanks.
VS Code version: Code 1.61.0 (ee8c7def80afc00dd6e593ef12f37756d8f504ea, 2021-10-07T18:13:09.652Z)
OS version: Windows_NT x64 10.0.19043
Restricted Mode: No
System Info
gpu_compositing: enabled
multiple_raster_threads: enabled_on
oop_rasterization: unavailable_off
opengl: enabled_on
rasterization: unavailable_off
skia_renderer: enabled_on
video_decode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: unavailable_off
Process Info
Workspace Info
Extensions (77)
(3 theme extensions excluded)
A/B Experiments
The text was updated successfully, but these errors were encountered: