microsoft / microsoft/TypeScript
IntelliSense not functioning in large project sometimes
Nadie ha tomado este issue todavía.
- Lenguaje dominante
- Go
- Estrellas
- 111k
- Forks
- 14.3k
- Merge medio
- 1 d 19 h
- PR fusionados (30 d)
- 117
Descripción
🔎 Search Terms
language server loading
updateGraphWorker
IntelliSense not working
🕗 Version & Regression Information
- This is a crash
- This changed between versions ______ and _______
- This changed in commit or PR _______
- This is the behavior in every version I tried, and I reviewed the FAQ for entries about _________
- I was unable to test this on prior versions because _______
⏯ Playground Link
No response
💻 Code
No response
🙁 Actual behavior
While working on a large TypeScript project, we have encountered a decline in the developer experience as the project continues to grow. One particular issue we have experienced is that IntelliSense consistently gets stuck without any apparent reason. To investigate this further, I attempted to enable the debug mode of the TypeScript server and discovered that it hangs at the updateGraphWorker stage.
Info 17820[15:27:03.183] -----------------------------------------------
Info 17820[15:27:03.195] event:
{"seq":0,"type":"event","event":"projectLoadingFinish","body":{"projectName":"/path/to/some/json"}}
Info 17820[15:27:03.202] event:
{"seq":0,"type":"event","event":"telemetry","body":{"telemetryEventName":"projectInfo","payload":{"projectId":"xxxx","fileStats":{"js":0,"jsSize":0,"jsx":0,"jsxSize":0,"ts":1744,"tsSize":2689631,"tsx":108,"tsxSize":347124,"dts":3944,"dtsSize":8979876,"deferred":0,"deferredSize":0},"compilerOptions":{"experimentalDecorators":true,"emitDecoratorMetadata":true,"strict":true,"allowUnreachableCode":false,"outDir":"","target":"es2022","declaration":true,"module":"esnext","esModuleInterop":true,"moduleResolution":"node10","verbatimModuleSyntax":true,"useDefineForClassFields":false,"sourceMap":true,"skipLibCheck":true,"plugins":[""],"jsx":"preserve","baseUrl":"","paths":"","composite":true,"rootDir":"","declarationDir":"","resolveJsonModule":true},"typeAcquisition":{"enable":false,"include":false,"exclude":false},"extends":true,"files":false,"include":true,"exclude":false,"compileOnSave":false,"configFileName":"tsconfig.json","projectType":"configured","languageServiceEnabled":true,"version":"5.2.2"}}}
Info 17820[15:27:03.203] Creating configuration project /path/to/some/json
Info 17820[15:27:03.203] event:
{"seq":0,"type":"event","event":"projectLoadingStart","body":{"projectName":"/path/to/some/json"}}
Info 17820[15:27:03.204] FileWatcher:: Added:: WatchInfo: /path/to/some/ts 500 undefined WatchType: Closed Script info
Info 17821[15:27:03.205] FileWatcher:: Added:: WatchInfo: /path/to/some/ts 500 undefined WatchType: Closed Script info
Info 17821[15:27:03.206] FileWatcher:: Added:: WatchInfo: /path/to/some/ts 500 undefined WatchType: Closed Script info
Info 17821[15:27:03.206] FileWatcher:: Added:: WatchInfo: /path/to/some/ts 500 undefined WatchType: Closed Script info
Info 17821[15:27:03.207] FileWatcher:: Added:: WatchInfo: /path/to/some/ts 500 undefined WatchType: Closed Script info
Info 17821[15:27:03.207] FileWatcher:: Added:: WatchInfo: /path/to/some/ts 500 undefined WatchType: Closed Script info
Info 17821[15:27:03.208] FileWatcher:: Added:: WatchInfo: /path/to/some/ts 500 undefined WatchType: Closed Script info
Info 17821[15:27:03.223] Starting updateGraphWorker: Project: /path/to/some/json
Info 17821[15:27:03.311] DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17821[15:27:03.311] Elapsed:: 0.012974977493286133ms DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17821[15:27:03.311] DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17822[15:27:03.311] Elapsed:: 0.0058460235595703125ms DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17822[15:27:03.311] DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17822[15:27:03.311] Elapsed:: 0.0055010318756103516ms DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17822[15:27:03.311] DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17822[15:27:03.311] Elapsed:: 0.011311054229736328ms DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17822[15:27:03.311] DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17822[15:27:03.311] Elapsed:: 0.004781007766723633ms DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17822[15:27:03.312] DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17822[15:27:03.312] Elapsed:: 0.008038997650146484ms DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17822[15:27:03.312] FileWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: File location affecting resolution
Info 17823[15:27:03.316] DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17823[15:27:03.316] Elapsed:: 0.010488033294677734ms DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17823[15:27:03.317] FileWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: File location affecting resolution
Info 17823[15:27:03.319] FileWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: File location affecting resolution
Info 17823[15:27:03.322] FileWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: File location affecting resolution
Info 17823[15:27:03.824] DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17823[15:27:03.824] Elapsed:: 0.0059119462966918945ms DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17823[15:27:03.915] DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17823[15:27:03.915] Elapsed:: 0.008075952529907227ms DirectoryWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: Failed Lookup Locations
Info 17823[15:27:04.015] FileWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: File location affecting resolution
Info 17824[15:27:04.532] FileWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: File location affecting resolution
Info 17824[15:27:05.703] FileWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: File location affecting resolution
Info 17824[15:27:05.748] FileWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: File location affecting resolution
Info 17824[15:27:07.812] FileWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: File location affecting resolution
Info 17824[15:27:07.843] FileWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: File location affecting resolution
Info 17824[15:27:08.790] FileWatcher:: Added:: WatchInfo: /path/to/some/json WatchType: File location affecting resolution
# log stops here
🙂 Expected behavior
In our large project, we expect IntelliSense to work smoothly since the project can be type checked within approximately 2 minutes.
Additional information about the issue
No response
Guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Línea de trabajo
Comienza reproduciendo el bloqueo de IntelliSense en un proyecto grande y capturando el TypeScript server debug log alrededor de updateGraphWorker, la etapa identificada en la que se detiene el informe. Investiga la actividad de carga del proyecto y del observador de archivos que se muestra en el log; se considera terminado cuando IntelliSense completa la carga del proyecto y sigue siendo utilizable en lugar de quedarse bloqueado.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- typescript
- Área
- developer-experience, tooling
- Tipo de issue
- Error
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Estado de actividad
- Estancado
- Claridad
- Necesita aclaración
- Aptitud para principiantes
- 30/100