microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
162.69k stars 28.69k forks source link

TS Server fatal error: Debug Failure. False expression: Script kind should match provided ScriptKind:3 and sourceFile.scriptKind: 1, !entry: false #218621

Closed ShinchanNoharaCN closed 2 months ago

ShinchanNoharaCN commented 2 months ago

Type: Bug

❗️❗️❗️ Please fill in the sections below to help us diagnose the issue ❗️❗️❗️

TypeScript Version: 5.4.5

Steps to reproduce crash

1. 2. 3.

Global TypeScript Server Plugins

❗️ Please test with extensions disabled. Extensions are the root cause of most TypeScript server crashes

TS Server Log

❗️ Server logging disabled. To help us fix crashes like this, please enable logging by setting:

"typescript.tsserver.log": "verbose"

After enabling this setting, future crash reports will include the server log.

VS Code version: Code - Insiders 1.90.0-insider (f209ce35ef894bd32c12057724e8d1f1139c433f, 2024-05-17T17:49:32.956Z) OS version: Windows_NT x64 10.0.22631 Modes: Unsupported

System Info |Item|Value| |---|---| |CPUs|Intel(R) Core(TM) i7-8700K ES CPU @3.20 GHz (12 x 2792)| |GPU Status|2d_canvas: enabled
canvas_oop_rasterization: enabled_on
direct_rendering_display_compositor: disabled_off_ok
gpu_compositing: enabled
multiple_raster_threads: enabled_on
opengl: enabled_on
rasterization: enabled
raw_draw: disabled_off_ok
skia_graphite: disabled_off
video_decode: enabled
video_encode: enabled
vulkan: disabled_off
webgl: enabled
webgl2: enabled
webgpu: enabled| |Load (avg)|undefined| |Memory (System)|31.91GB (14.90GB free)| |Process Argv|C:\\Users\\34611\\Desktop\\electron-demo --crash-reporter-id 4f080c05-9d1e-41e2-8a99-6b3841558de9| |Screen Reader|no| |VM|0%|
Extensions (55) Extension|Author (truncated)|Version ---|---|--- vscode-javascript-snippet-pack|aka|0.1.6 codegeex|AMi|2.11.0 unocss|ant|0.61.0 vscode-custom-css|be5|7.2.2 vscode-animations|Bra|2.0.2 java-run|cao|1.1.4 path-intellisense|chr|2.9.0 zh-hans-tt-hant-vscode|cip|1.0.0 vscode-eslint|dba|3.0.10 shaderinspector|Dmy|1.0.2 apc-extension|drc|0.3.9 vscode-html-css|ecm|2.0.10 vsc-material-theme|Equ|34.4.0 vsc-material-theme-icons|equ|3.6.1 prettier-vscode|esb|10.4.0 auto-rename-tag|for|0.1.10 vscode-pull-request-github|Git|0.90.0 vue-snippets|hol|1.0.4 iconify-preview|hun|0.7.3 path-autocomplete|ion|1.25.0 i18n-ally|lok|2.12.0 html5-template-snippet|mar|1.0.3 dotenv|mik|1.0.1 vscode-dotnet-runtime|ms-|2.0.7 debugpy|ms-|2024.6.0 python|ms-|2024.8.1 vscode-pylance|ms-|2024.6.1 remote-containers|ms-|0.374.0 java-prettier-formatter|mwp|0.1.6 webgl-glsl-editor|rac|1.3.8 java|red|1.32.2024062619 LiveServer|rit|5.7.9 synthwave-vscode|Rob|0.1.15 vscode-scss-formatter|sib|3.0.0 html5-boilerplate|sid|1.1.1 win-opacity|ska|1.1.7 shader|sle|1.1.5 autoimport|ste|1.5.4 shader-toy|ste|0.11.2 code-spell-checker|str|3.0.1 vscode-stylelint|sty|1.4.0 sass-indented|syl|1.8.29 errorlens|use|3.20.0 intellicode-api-usage-examples|Vis|0.2.8 vscodeintellicode|Vis|1.3.1 vscode-java-debug|vsc|0.57.2024061805 vscode-java-dependency|vsc|0.23.2024062100 vscode-java-pack|vsc|0.27.2024062103 vscode-java-test|vsc|0.41.2024061208 vscode-maven|vsc|0.44.2024013105 volar|Vue|2.0.22 console-ninja|Wal|1.0.326 html-snippets|wsc|1.0.6 JavaScriptSnippets|xab|1.8.0 markdown-all-in-one|yzh|3.6.2 (5 theme extensions excluded)
A/B Experiments ``` vsliv368cf:30146710 vspor879:30202332 vspor708:30202333 vspor363:30204092 vswsl492:30256197 vstes627:30244334 vscod805:30301674 vsaa593cf:30376535 py29gd2263:31024238 c4g48928:30535728 962ge761:30841072 pythongtdpath:30726887 welcomedialogc:30812479 pythonnoceb:30776497 asynctok:30898717 dsvsc013:30777762 dsvsc014:30777825 dsvsc015:30821418 pythonregdiag2:30926734 pythonmypyd1:30859725 h48ei257:31000450 pythontbext0:30879054 accentitlementst:30870582 dsvsc016:30879898 dsvsc017:30880771 dsvsc018:30880772 cppperfnew:30980852 pythonait:30973460 jchc7451:31067543 chatpanelt:31014475 bdiig495:31013172 a69g1124:31018687 dvdeprecation:31040973 dwnewjupyter:31046869 legacy_priority:31057981 nativerepl1:31071684 pythonrstrctxt:31083681 ```
mjbvz commented 2 months ago

❗️ Please test with extensions disabled. Extensions are the root cause of most TypeScript server crashes

The issue tells you the likely problem. Please try following these instructions before reporting an issue against VS Code