Repository navigation
Closed
Labels
BugA bug in TypeScriptA bug in TypeScriptFixedA PR has been merged for this issueA PR has been merged for this issueVS Code TrackedThere is a VS Code equivalent to this issueThere is a VS Code equivalent to this issue
Milestone
Description
From ChiefORZ on May 30, 2017 11:28
- VSCode Version: Code 1.12.2 (19222cdc84ce72202478ba1cec5cb557b71163de, 2017-05-10T13:20:36.315Z)
- OS Version: Windows_NT ia32 6.1.7601
- Extensions:
| Extension | Author | Version |
|---|---|---|
| project-manager | alefragnani | 0.18.0 |
| one-monokai | azemoh | 0.2.4 |
| npm-intellisense | christian-kohler | 1.3.0 |
| path-intellisense | christian-kohler | 1.4.2 |
| erb | CraigMaslowski | 0.0.1 |
| vscode-eslint | dbaeumer | 1.2.11 |
| githistory | donjayamanne | 0.2.0 |
| gitlens | eamodio | 3.5.1 |
| EditorConfig | EditorConfig | 0.9.3 |
| prettier-vscode | esbenp | 0.17.1 |
| vscode-console-wrapper | fabiodam | 0.4.0 |
| php-debug | felixfbecker | 1.10.0 |
| sublime-babel-vscode | joshpeng | 0.2.5 |
| atom-keybindings | ms-vscode | 2.0.1 |
| sort-imports | peterjuras | 2.3.1 |
| better-merge | pprice | 0.7.0 |
| code-settings-sync | Shan | 2.8.1 |
| gitflow | vector-of-bool | 1.1.0 |
| vscode-react-native | vsmobile | 0.3.2 |
| JavaScriptSnippets | xabikos | 1.4.0 |
| ReactSnippets | xabikos | 1.3.0 |
| Material-theme | zhuangtongfa | 2.8.1 |
Resolving modules and Intellisense Autocompletion in our Project takes a long time...
Maybe this problem is a result of using absolute paths.
Here is our jsconfig.json of the project:
{
"compilerOptions": {
"target": "es6",
"module": "es6",
"baseUrl": "./", // all paths are relative to the baseUrl
"paths": {
"~/*" : ["*"] // resolve any `~/foo/bar` to `<baseUrl>/foo/bar`
}
},
"exclude": [
"api",
"build",
"node_modules",
"public",
"seeds",
"sql_updates",
"tests.build"
]
}
Can i somehow debug which directories VSCode is resolving to find my correct file.
And is there maybe a way to cache this resolved pathy specific for this IDE on my Client... to make the IDE not search my Filesystem every time - or do you plan on make this in the future
Copied from original issue: microsoft/vscode#27539
Reacted by Russell Dempsey
Metadata
Metadata
Assignees
Labels
BugA bug in TypeScriptA bug in TypeScriptFixedA PR has been merged for this issueA PR has been merged for this issueVS Code TrackedThere is a VS Code equivalent to this issueThere is a VS Code equivalent to this issue

Activity
mjbvz commentedon Jun 7, 2017
From ChiefORZ on May 30, 2017 11:30
Maybe it is, because our Project has about 550 Files in 120 Folders?
(excluding all folders mentioned above)
mjbvz commentedon Jun 7, 2017
From Nish (@nishp1) on May 31, 2017 23:26
We have a similar problem as well. We have ~900 folders with ~3900 files.
Here is the tsconfig.json we are using:
I often see "Loading..." while module path is being resolved. Even when path is resolved (displayed as tooltip/quickinfo),
cmd + clicktakes a good 2 to 10 seconds to open the file. Happy to share more info if I know how to debug this.mjbvz commentedon Jun 7, 2017
To investigate what is causing this slowdown, please try collecting the typescript server log:
"typescript.tsserver.log": "verbose"--disable-extensionscommand line flag to disable all extensions.Open TSServer log Filecommand and view thetsserver.logfileEach request to the tsserver should have timing information. Look for the
quickInforequests and responses towards the end of the logs. If you can share the log file I can take a look through them to see if anything stands outmjbvz commentedon Jun 7, 2017
From ChiefORZ on June 2, 2017 8:37
Thanks for the response!
Made the server log executing only the issued problem. The
quickInforequest does really need 11 seconds to execute...here is my logfile. thanks for taking time for it :)
tsserver.zip
mjbvz commentedon Jun 7, 2017
From Nish (@nishp1) on June 2, 2017 14:39
Thanks Matt Bierner (@mjbvz). Attached are verbose logs for Today's insider version (f977399). Grepping for "elapsed", I see logs ranging from 1ms to 18s.
tsserver.log.zip
Let me know if there is anything else I can do to provide more info.
mjbvz commentedon Jun 7, 2017
From Georgii Dolzhykov (@thorn0) on June 4, 2017 21:31
I'm getting a similar effect with only 2 files in the project, one of which is a module that exports a big array, and the second file imports this module. At first after Code starts everything is fine, but then autocompletion becomes increasingly slow. This project and the logs can be found here. Might be a good isolated illustration of the issue.
vscode: 1.13.0-insider f977399
ts 2.3.4
mjbvz commentedon Jun 7, 2017
From Nish (@nishp1) on June 5, 2017 17:1
I was trying to debug typescript server over the weekend but oss version didn't load builtin extensions nor let me install chrome debugger to debug typescript server. Is there an argument I need to pass in to enable extensions in dev?
22 remaining items
giannif commentedon Sep 14, 2017
I have the same issue as Titouan (@titouandk), everything has been super speedy for months, and then I added what's below to my tsconfig.json and now resolution takes a few seconds
Removing it and restarting and it's back to speedy
sheetalkamat commentedon Oct 4, 2017
This should be fixed now. Can you please give a try to typescript@next
titouandk commentedon Oct 5, 2017
Thank you, it works like a charm!
Just in case, here is the procedure to upgrade VSCode typescript version:
https://code.visualstudio.com/docs/languages/typescript#_using-newer-typescript-versions
nishp1 commentedon Oct 5, 2017
Thank you Sheetal Nandi (@sheetalkamat). Intellisense is on 🔥 on a project with 4500+ files.
ChiefORZ commentedon Oct 5, 2017
Tried to adding the newest version of Typescript globally, and locally... Always getting the same errors:
tsserver.log
mhegazy commentedon Oct 5, 2017
Seems like you are running into a different issue:
mhegazy commentedon Oct 5, 2017
can you share some repro code?
ChiefORZ commentedon Oct 6, 2017
https://github.com/ChiefORZ/ts-resolve
as soon as i try to do anything, i get the error message:
tsserver.log
ChiefORZ commentedon Oct 10, 2017
Ok, i tracked this Bug a bit and i found out that our dependencies in the
node_modulesfolder in combination with the amount of files in our repository is causing the problem.https://github.com/ChiefORZ/ts-resolve
Please clone the repo - i removed all our business logik from it.
Install all dependencies via
yarnAnd try out the Intellisense
sheetalkamat commentedon Oct 11, 2017
I tried this with typescript@2.6.0-dev.20171011 and i cant repro this issue. There was no exception and the completions, quickinfo, goto definitions seem to work. tsserver.log
It is possible that the reason you first saw exception before was addressed by #19053
Can you please try typescript@next to see if things are working at your end.