Closed xBoyMinemc closed 1 year ago
Thanks for creating this issue! It looks like you may be using an old version of VS Code, the latest stable release is 1.73.1. Please try upgrading to the latest version and checking whether this issue remains.
Happy Coding!
Thanks, just finished the update, I'll program and wait for it happen again
maybe restart again?
https://user-images.githubusercontent.com/86919167/201116082-0b80a17d-0a38-462a-a248-100701f38a41.mp4 (did the video break?i cant load it)
Please teach me how to provide more information
Does this reproduce in the latest VS Code insiders build with all extensions disabled?
yes, 1.17.31 Updated eight hours ago,and disable all extensions, Even includes language adaptation packages
How can I provide more useful information next?
maybe reinstall? i updataed by VS Code setting.
Please test in VS Code insiders. This should be VS Code 1.74
funny,look this ,but before 4.8.4 i just do no thing and ready to Update in VS Code insiders.
OHHH VS Code insiders work well, but I'll watch for a few days
--thanks
ohhh,funny again
VS Code insiders work wrong :(
i just want to finsh my toys
TS Server fatal error: path.charCodeAt is not a function
Type: Bug
❗️❗️❗️ Please fill in the sections below to help us diagnose the issue ❗️❗️❗️
TypeScript Version: 4.9.2-rc
Steps to reproduce crash
1.i do no thing
2.just open my VSC with my working files
3.https://github.com/microsoft/TypeScript/issues/51518
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.
TS Server Error Stack
Server: semantic
TypeError: path.charCodeAt is not a function
at getEncodedRootLength (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:7693:24)
at getRootLength (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:7770:26)
at combinePaths (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:7964:26)
at getPathComponents (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:7875:16)
at getNormalizedPathComponents (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:8003:37)
at Object.getNormalizedAbsolutePath (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:8007:42)
at normalizeNonListOptionValue (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:42889:24)
at normalizeOptionValue (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:42885:16)
at c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:42878:70
at Object.map (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:460:29)
at normalizeOptionValue (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:42878:37)
at Object.onSetValidOptionKeyValueInParent (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:42702:46)
at _loop_4 (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:41961:56)
at convertObjectLiteralExpressionToJson (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:41979:17)
at convertPropertyValueToJson (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:42038:46)
at _loop_4 (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:41948:29)
at convertObjectLiteralExpressionToJson (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:41979:17)
at convertPropertyValueToJson (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:42038:46)
at convertToObjectWorker (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:41920:16)
at convertConfigFileToObject (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:41900:16)
at parseOwnConfigOfJsonSourceFile (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:42723:20)
at parseConfig (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:42619:13)
at parseJsonConfigFileContentWorker (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:42435:28)
at Object.parseJsonSourceFileConfigFileContent (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:42398:22)
at ProjectService.ensureParsedConfigUptoDate (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:177091:44)
at ProjectService.loadConfiguredProject (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:177036:52)
at ProjectService.createAndLoadConfiguredProject (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:177017:22)
at ProjectService.createLoadAndUpdateConfiguredProject (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:177022:36)
at ProjectService.assignProjectToOpenedScriptInfo (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:178108:44)
at c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:178448:97
at Object.flatMap (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:524:25)
at ProjectService.applyChangesInOpenFiles (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:178448:41)
at Session.handlers.ts.Map.ts.getEntries._a.<computed> (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:179820:46)
at c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:182013:96
at Session.executeWithRequestId (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:182004:28)
at Session.executeCommand (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:182013:41)
at Session.onMessage (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:182041:35)
at process.<anonymous> (c:\Users\云梦\AppData\Local\Programs\Microsoft VS Code Insiders\resources\app\extensions\node_modules\typescript\lib\tsserver.js:186197:31)
at process.emit (node:events:526:28)
at emit (node:internal/child_process:938:14)
at process.processTicksAndRejections (node:internal/process/task_queues:84:21)
VS Code version: Code - Insiders 1.74.0-insider (ef415578d1b1019db585718968a303eeca4b8979, 2022-11-11T05:19:14.666Z) OS version: Windows_NT x64 10.0.19044 Modes: Unsupported Sandboxed: Yes
and>>> what's happen? CPU BOOM
after kill it:
any some body here?
Can't work by this for six days ):
Having the same issue -
@xBoyMinemc Please try collecting the TS Server log from the crashed instance:
"typescript.tsserver.log": "verbose"
TypeScript
section of the output panelAt the very top, find the first line that prints to path to the semantic error log file. It should look something like:
[Info - 19:54:59.247] <semantic> Log file: /Users/matb/Library/Application Support/Code - Insiders/logs/20200213T104930/exthost55/vscode.typescript-language-features/tsserver-log-ZT2zau/tsserver.log
That file contains the typescript logs.
Please share this log so we can try to see why the server is crashing (and also so we can confirm that TS Server plugins are not causing this)
⚠️Warning: The TypeScript log may include information from your workspace, including file paths and source code. If you have any concerns about posting this publicly on Github, just let me know and we can arrange something else. On our side, we only use these logs to investigate issues like this
Personal computers, theoretically do not contain sensitive information
and i think,,,,,
CPU usage is high because log files are created continuously and some programs try to restart
This is because your package has a tsconfig.json
with unterminated baseUrl
and typeRoots
properties:
{
"compilerOptions": {
"module": "commonjs",
"lib": ["es6"],
"target": "es6",
"forceConsistentCasingInFileNames": true,
"noEmit": true,
"noImplicitAny": true,
"noImplicitThis": true,
"strictFunctionTypes": true,
"strictNullChecks": true,
// !!!!!
"baseUrl": "..,
"typeRoots": ["..],
"types": []
},
"files": [
"index.d.ts"
]
}
On our side the fix is easy - we need to validate that when we check option.isFilePath
that the current value is actually a string
.
- if (option.isFilePath) {
+ if (option.isFilePath && typeof value === "string") {
oh!Who says no hero in the human !!!!!!!!!!!!!!!
I will continue to use it,and close it in a few days
---thanks
This is still a bug in our compiler - please leave this open until it's resolved.
The crash was fixed with #53331
Upgrade typescript
to v5+
.
Apart from this, if you're using any bundlers (e.g., Rollup, Webpack), don't forget to upgrade their TypeScript-related packages as well.
I had to upgrade rollup-plugin-ts
.
Does this issue occur when all extensions are disabled?: Yes
VS Code Version: 1.73.0 %8fa188b2b301d36553cbc9ce1b0a146ccb93351f %x64
OS Version: 21H2 for home %19044.1889
Steps to Reproduce:
normal :
crash :