Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TS Server fatal error: Cannot read property 'indexOf' of undefined #118093

Closed
jamie-wearsafe opened this issue Mar 4, 2021 · 1 comment
Closed
Assignees
Labels
*duplicate Issue identified as a duplicate of another issue(s)

Comments

@jamie-wearsafe
Copy link

Issue Type: Bug

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

TypeScript Version: 4.1.4

Steps to reproduce crash
1.
2.
3.

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: Cannot read property 'indexOf' of undefined
    at Object.parsePackageName (/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:39472:30)
    at ConfiguredProject.Project.enablePlugin (/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:151962:24)
    at ConfiguredProject.enablePluginsWithOptions (/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:152477:30)
    at ProjectService.loadConfiguredProject (/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:154206:25)
    at ProjectService.createAndLoadConfiguredProject (/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:154145:22)
    at ProjectService.createLoadAndUpdateConfiguredProject (/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:154150:36)
    at ProjectService.assignProjectToOpenedScriptInfo (/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:155055:44)
    at /Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:155395:97
    at Object.flatMap (/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:513:25)
    at ProjectService.applyChangesInOpenFiles (/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:155395:41)
    at Session.handlers.ts.Map.ts.getEntries._a.<computed> (/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:156413:46)
    at /Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:158286:88
    at IOSession.Session.executeWithRequestId (/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:158277:28)
    at IOSession.Session.executeCommand (/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:158286:33)
    at IOSession.Session.onMessage (/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:158310:35)
    at Interface.<anonymous> (/Applications/Visual Studio Code.app/Contents/Resources/app/extensions/node_modules/typescript/lib/tsserver.js:160520:27)
    at Interface.emit (events.js:315:20)
    at Interface._onLine (readline.js:329:10)
    at Interface._normalWrite (readline.js:474:12)
    at Socket.ondata (readline.js:186:10)
    at Socket.emit (events.js:315:20)
    at addChunk (_stream_readable.js:295:12)
    at readableAddChunk (_stream_readable.js:271:9)
    at Socket.Readable.push (_stream_readable.js:212:10)
    at Pipe.onStreamRead (internal/stream_base_commons.js:186:23)

VS Code version: Code 1.53.1 (5d424b8, 2021-02-08T23:35:15.302Z)
OS version: Darwin x64 20.3.0

System Info
Item Value
CPUs Intel(R) Core(TM) i7-6820HQ CPU @ 2.70GHz (8 x 2700)
GPU Status 2d_canvas: enabled
gpu_compositing: enabled
metal: disabled_off
multiple_raster_threads: enabled_on
oop_rasterization: enabled
opengl: enabled_on
protected_video_decode: unavailable_off
rasterization: enabled
skia_renderer: disabled_off_ok
video_decode: enabled
webgl: enabled
webgl2: enabled
Load (avg) 9, 5, 4
Memory (System) 16.00GB (0.50GB free)
Process Argv --crash-reporter-id 226b7d9c-b212-49bf-88aa-a77ab4d5b702
Screen Reader no
VM 0%
Extensions (72)
Extension Author (truncated) Version
node-essentials afr 1.1.0
aws-toolkit-vscode ama 1.20.0
vscode-apollo apo 1.18.2
vscode-icontheme-nomo-dark be5 1.3.6
markdown-preview-github-styles bie 0.1.6
prettier-vscode-standard bys 0.22.1
language-prometheus caa 0.1.2
path-intellisense chr 2.3.0
vscode-markdownlint Dav 0.39.0
vscode-eslint dba 2.1.14
xml Dot 2.5.1
vscode-remark-lint dre 1.0.0
gitlens eam 11.2.1
EditorConfig Edi 0.16.4
RunOnSave eme 0.2.0
prettier-vscode esb 5.9.2
vscode-diff fab 1.4.0
shell-format fox 7.0.1
pythonsnippets frh 1.0.2
vscode-codeql Git 1.4.3
vscode-pull-request-github Git 0.23.0
pyformat giy 1.0.2
go gol 0.22.1
vscode-graphql Gra 0.3.15
terraform has 2.7.0
vscode-test-explorer hbe 2.19.5
auto-markdown-toc hun 3.0.12
google-java-format ilk 1.0.2
vscode-cfn-lint kdd 0.15.6
vsc-python-indent Kev 1.12.0
graphql-for-vscode kum 1.15.3
code-groovy mar 0.1.2
pretty-formatter mbl 0.2.2
dotenv mik 1.0.1
vscode-docker ms- 1.10.0
vscode-kubernetes-tools ms- 1.3.0
python ms- 2021.2.582707922
vscode-pylance ms- 2021.3.0
jupyter ms- 2021.2.603412351
remote-containers ms- 0.158.0
vscode-typescript-tslint-plugin ms- 1.3.3
debugger-for-chrome msj 4.12.12
sqltools mtx 0.23.0
vscode-groovy-lint Nic 1.4.0
vetur oct 0.33.0
vscode-jest Ort 3.2.0
geo-data-viewer Ran 2.3.0
fabric8-analytics red 0.3.2
java red 0.75.0
vscode-commons red 0.0.4
vscode-xml red 0.15.0
vscode-yaml red 0.15.0
terraform-comments-beautifier sah 0.0.3
jenkinsfile-support sec 0.1.0
vscode-checkstyle she 1.4.0
sonarlint-vscode Son 1.20.1
code-spell-checker str 1.10.2
serverless-ide-vscode Thr 0.5.30
shellcheck tim 0.13.2
sort-lines Tyr 1.9.0
vscodeintellicode Vis 1.2.11
vscode-java-debug vsc 0.31.0
vscode-java-dependency vsc 0.18.1
vscode-java-pack vsc 0.12.1
vscode-java-test vsc 0.28.0
vscode-maven vsc 0.27.1
quokka-vscode Wal 1.0.345
vscode-import-cost wix 2.15.0
google-java-format wx- 0.0.1
linecount yyc 0.1.7
markdown-all-in-one yzh 3.4.0
makefile-creator zen 0.0.3

(2 theme extensions excluded)

@mjbvz
Copy link
Collaborator

mjbvz commented Mar 4, 2021

Duplicate of #116219

Please update to VS Code 1.53.2

@mjbvz mjbvz closed this as completed Mar 4, 2021
@mjbvz mjbvz added the *duplicate Issue identified as a duplicate of another issue(s) label Mar 4, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Apr 18, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
*duplicate Issue identified as a duplicate of another issue(s)
Projects
None yet
Development

No branches or pull requests

2 participants