TypeScript: TypeScript Server Error (5.2.2) on update to 1.82.0
Not sure if this can be reproduced yet. Just updated VSCode which includes TypeScript 5.2.2 and this error occurred. Will modify/update this report with proper process and logs if I can get more info. Given the extensions reported in this error, it’s not apparent to me yet if this is a VSCode issue or an extensions issue, but “something” in the new update just broke “something”, and I’m starting here with the diagnostics. Will also advise extension authors.
<semantic> TypeScript Server Error (5.2.2)
Debug Failure. False expression.
Error: Debug Failure. False expression.
at _NodeTypingsInstaller.installPackage (c:\Program Files\Microsoft VS Code\resources\app\extensions\node_modules\typescript\lib\tsserver.js:186191:13)
at TypingsCache.installPackage (c:\Program Files\Microsoft VS Code\resources\app\extensions\node_modules\typescript\lib\tsserver.js:175906:27)
at ConfiguredProject2.installPackage (c:\Program Files\Microsoft VS Code\resources\app\extensions\node_modules\typescript\lib\tsserver.js:176180:30)
at applySingleCodeActionCommand (c:\Program Files\Microsoft VS Code\resources\app\extensions\node_modules\typescript\lib\tsserver.js:144424:39)
at Proxy.applyCodeActionCommand (c:\Program Files\Microsoft VS Code\resources\app\extensions\node_modules\typescript\lib\tsserver.js:144419:96)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\mxsdev.typescript-explorer-0.4.2\node_modules\@ts-type-explorer\typescript-plugin\dist\index.js:15:15)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-extract-object-binding-type-literal-plugin\index.js:21:26)
at proxy.<computed> (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-react-utils-plugin\index.js:21:26)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\mxsdev.typescript-explorer-0.4.2\node_modules\@ts-type-explorer\typescript-plugin\dist\index.js:15:15)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-extract-object-binding-type-literal-plugin\index.js:21:26)
at proxy.<computed> (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-react-utils-plugin\index.js:21:26)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\mxsdev.typescript-explorer-0.4.2\node_modules\@ts-type-explorer\typescript-plugin\dist\index.js:15:15)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-extract-object-binding-type-literal-plugin\index.js:21:26)
at proxy.<computed> (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-react-utils-plugin\index.js:21:26)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\mxsdev.typescript-explorer-0.4.2\node_modules\@ts-type-explorer\typescript-plugin\dist\index.js:15:15)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-extract-object-binding-type-literal-plugin\index.js:21:26)
at proxy.<computed> (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-react-utils-plugin\index.js:21:26)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\mxsdev.typescript-explorer-0.4.2\node_modules\@ts-type-explorer\typescript-plugin\dist\index.js:15:15)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-extract-object-binding-type-literal-plugin\index.js:21:26)
at proxy.<computed> (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-react-utils-plugin\index.js:21:26)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\mxsdev.typescript-explorer-0.4.2\node_modules\@ts-type-explorer\typescript-plugin\dist\index.js:15:15)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-extract-object-binding-type-literal-plugin\index.js:21:26)
at proxy.<computed> (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-react-utils-plugin\index.js:21:26)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\mxsdev.typescript-explorer-0.4.2\node_modules\@ts-type-explorer\typescript-plugin\dist\index.js:15:15)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-extract-object-binding-type-literal-plugin\index.js:21:26)
at proxy.<computed> (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-react-utils-plugin\index.js:21:26)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\mxsdev.typescript-explorer-0.4.2\node_modules\@ts-type-explorer\typescript-plugin\dist\index.js:15:15)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-extract-object-binding-type-literal-plugin\index.js:21:26)
at proxy.<computed> [as applyCodeActionCommand] (c:\Users\tonyg\.vscode\extensions\paulshen.paul-typescript-toolkit-0.0.6\node_modules\typescript-react-utils-plugin\index.js:21:26)
at IpcIOSession.applyCodeActionCommand (c:\Program Files\Microsoft VS Code\resources\app\extensions\node_modules\typescript\lib\tsserver.js:184567:36)
at applyCodeActionCommand (c:\Program Files\Microsoft VS Code\resources\app\extensions\node_modules\typescript\lib\tsserver.js:182680:43)
at c:\Program Files\Microsoft VS Code\resources\app\extensions\node_modules\typescript\lib\tsserver.js:184838:69
at IpcIOSession.executeWithRequestId (c:\Program Files\Microsoft VS Code\resources\app\extensions\node_modules\typescript\lib\tsserver.js:184830:14)
at IpcIOSession.executeCommand (c:\Program Files\Microsoft VS Code\resources\app\extensions\node_modules\typescript\lib\tsserver.js:184838:29)
at IpcIOSession.onMessage (c:\Program Files\Microsoft VS Code\resources\app\extensions\node_modules\typescript\lib\tsserver.js:184880:51)
at process.<anonymous> (c:\Program Files\Microsoft VS Code\resources\app\extensions\node_modules\typescript\lib\tsserver.js:186461:14)
at process.emit (node:events:513:28)
at emit (node:internal/child_process:937:14)
at process.processTicksAndRejections (node:internal/process/task_queues:83:21)
Version: 1.82.0 (system setup) Commit: 8b617bd08fd9e3fc94d14adb8d358b56e3f72314 Date: 2023-09-06T22:07:07.438Z Electron: 25.8.0 ElectronBuildId: 23503258 Chromium: 114.0.5735.289 Node.js: 18.15.0 V8: 11.4.183.29-electron.0 OS: Windows_NT x64 10.0.19045
Current scenario: I just opened an existing workspace with a TypeScript / React project. Linting was reporting that lodash is not installed, but it is, and I believe this error displayed during a rebuild.
I will reload the environment to see if this reproduces, and will test with and without the extensions shown in the error to see if either one of them triggers the issue.
About this issue
- Original URL
- State: closed
- Created 10 months ago
- Reactions: 7
- Comments: 24 (8 by maintainers)
I don’t appear to hit this crash on TS
5.1.3
, which @mrmckeb suggested I try.Logs for that are here: https://gist.githubusercontent.com/ekilah/2a3385653c2101a268d320a87bb83c95/raw/32941e2856a048b60170c3acdb2cc984416e39f5/tsserver-deal-web-5.1.3.log
This is about the spot in the log file where I added whitespace to my
tsconfig
file, to compare to the earlier logs, at17:36:16
:Sorry. Got this wrong the first time. its
project.getLanguageService().getProgram()
This makes sure that language service gets updated through project and the states are matched.
The plugins shouldnt be using
languageService.getProgram()
insteadproject.getProgram()
to ensure there is no issue with synchronization between LS and project. This looks like external issue with the plugin rather than Typescript itselfI found my problem due to TypeScript-Plugin-CSS-MODULES. I no longer use it anymore
The extensions in the stack trace are definitely a red flag to me; we often see proxying extensions like these fail to pass through all parameters and break after an internal API change in TS. I think that’s more than likely what’s happening, but let me know if you can reproduce with those extensions disabled.