-
Notifications
You must be signed in to change notification settings - Fork 748
Open
Labels
Description
Got this error while swapping tabs.
Stack trace
panic handling request textDocument/inlayHint runtime error: slice bounds out of range [20991:20987] goroutine 1859256 [running]:
runtime/debug.Stack()
runtime/debug/stack.go:26 +0x64
github.com/microsoft/typescript-go/internal/lsp.(*Server).recover(0x1400021e008, 0x1406ca1e930)
github.com/microsoft/typescript-go/internal/lsp/server.go:579 +0x44
panic({0x100c06740?, 0x14160db0c60?})
runtime/panic.go:783 +0x120
github.com/microsoft/typescript-go/internal/ls/lsconv.(*Converters).LineAndCharacterToPosition(0x140167bdab8, {0x100d52610, 0x141016fac08}, {0x894790?, 0x1?})
github.com/microsoft/typescript-go/internal/ls/lsconv/converters.go:158 +0x234
github.com/microsoft/typescript-go/internal/ls/lsconv.(*Converters).FromLSPRange(0x140167bdab8, {0x100d52610, 0x141016fac08}, {{0x16fac08?, 0x141?}, {0x0?, 0x0?}})
github.com/microsoft/typescript-go/internal/ls/lsconv/converters.go:47 +0x4c
github.com/microsoft/typescript-go/internal/ls.(*LanguageService).ProvideInlayHint(0x140758d88a0, {0x100d54b48, 0x140758d8810}, 0x1406ca1e8d0)
github.com/microsoft/typescript-go/internal/ls/inlay_hints.go:38 +0x118
github.com/microsoft/typescript-go/internal/lsp.(*Server).handleInlayHint(0x140002a2000?, {0x100d54b48?, 0x140758d8810?}, 0x1415ebd7a70?, 0x90?)
github.com/microsoft/typescript-go/internal/lsp/server.go:973 +0x2c
github.com/microsoft/typescript-go/internal/lsp.init.func1.registerLanguageServiceDocumentRequestHandler[...].27({0x100d54b48, 0x140758d8810}, 0x1406ca1e930)
github.com/microsoft/typescript-go/internal/lsp/server.go:565 +0xe0
github.com/microsoft/typescript-go/internal/lsp.(*Server).handleRequestOrNotification(0x1400021e008, {0x100d54b80?, 0x14077484500?}, 0x1406ca1e930)
github.com/microsoft/typescript-go/internal/lsp/server.go:458 +0x128
github.com/microsoft/typescript-go/internal/lsp.(*Server).dispatchLoop.func1()
github.com/microsoft/typescript-go/internal/lsp/server.go:361 +0x34
created by github.com/microsoft/typescript-go/internal/lsp.(*Server).dispatchLoop in goroutine 4
github.com/microsoft/typescript-go/internal/lsp/server.go:381 +0x7a0
[Error - 8:27:24 PM] Request textDocument/inlayHint failed.
Message: InternalError: panic handling request textDocument/inlayHint: runtime error: slice bounds out of range [20991:20987]
Code: -32603
panic handling request textDocument/inlayHint runtime error: slice bounds out of range [20991:20987] goroutine 1859258 [running]:
runtime/debug.Stack()
runtime/debug/stack.go:26 +0x64
github.com/microsoft/typescript-go/internal/lsp.(*Server).recover(0x1400021e008, 0x14077a89440)
github.com/microsoft/typescript-go/internal/lsp/server.go:579 +0x44
panic({0x100c06740?, 0x14160db0cc0?})
runtime/panic.go:783 +0x120
github.com/microsoft/typescript-go/internal/ls/lsconv.(*Converters).LineAndCharacterToPosition(0x140167bdab8, {0x100d52610, 0x141016fac08}, {0x894790?, 0x1?})
github.com/microsoft/typescript-go/internal/ls/lsconv/converters.go:158 +0x234
github.com/microsoft/typescript-go/internal/ls/lsconv.(*Converters).FromLSPRange(0x140167bdab8, {0x100d52610, 0x141016fac08}, {{0x16fac08?, 0x141?}, {0x0?, 0x0?}})
github.com/microsoft/typescript-go/internal/ls/lsconv/converters.go:47 +0x4c
github.com/microsoft/typescript-go/internal/ls.(*LanguageService).ProvideInlayHint(0x140758d8c60, {0x100d54b48, 0x140758d8bd0}, 0x14077a893e0)
github.com/microsoft/typescript-go/internal/ls/inlay_hints.go:38 +0x118
github.com/microsoft/typescript-go/internal/lsp.(*Server).handleInlayHint(0x140002a2000?, {0x100d54b48?, 0x140758d8bd0?}, 0x1415ec02bd0?, 0x90?)
github.com/microsoft/typescript-go/internal/lsp/server.go:973 +0x2c
github.com/microsoft/typescript-go/internal/lsp.init.func1.registerLanguageServiceDocumentRequestHandler[...].27({0x100d54b48, 0x140758d8bd0}, 0x14077a89440)
github.com/microsoft/typescript-go/internal/lsp/server.go:565 +0xe0
github.com/microsoft/typescript-go/internal/lsp.(*Server).handleRequestOrNotification(0x1400021e008, {0x100d54b80?, 0x140774845a0?}, 0x14077a89440)
github.com/microsoft/typescript-go/internal/lsp/server.go:458 +0x128
github.com/microsoft/typescript-go/internal/lsp.(*Server).dispatchLoop.func1()
github.com/microsoft/typescript-go/internal/lsp/server.go:361 +0x34
created by github.com/microsoft/typescript-go/internal/lsp.(*Server).dispatchLoop in goroutine 4
github.com/microsoft/typescript-go/internal/lsp/server.go:381 +0x7a0
[Error - 8:27:24 PM] Request textDocument/inlayHint failed.
Message: InternalError: panic handling request textDocument/inlayHint: runtime error: slice bounds out of range [20991:20987]
Code: -32603
panic handling request textDocument/inlayHint runtime error: slice bounds out of range [20991:20987] goroutine 1859259 [running]:
runtime/debug.Stack()
runtime/debug/stack.go:26 +0x64
github.com/microsoft/typescript-go/internal/lsp.(*Server).recover(0x1400021e008, 0x14077a894a0)
github.com/microsoft/typescript-go/internal/lsp/server.go:579 +0x44
panic({0x100c06740?, 0x14160db0cd8?})
runtime/panic.go:783 +0x120
github.com/microsoft/typescript-go/internal/ls/lsconv.(*Converters).LineAndCharacterToPosition(0x140167bdab8, {0x100d52610, 0x141016fac08}, {0x894790?, 0x1?})
github.com/microsoft/typescript-go/internal/ls/lsconv/converters.go:158 +0x234
github.com/microsoft/typescript-go/internal/ls/lsconv.(*Converters).FromLSPRange(0x140167bdab8, {0x100d52610, 0x141016fac08}, {{0x16fac08?, 0x141?}, {0x0?, 0x0?}})
github.com/microsoft/typescript-go/internal/ls/lsconv/converters.go:47 +0x4c
github.com/microsoft/typescript-go/internal/ls.(*LanguageService).ProvideInlayHint(0x140758d8e40, {0x100d54b48, 0x140758d8de0}, 0x14077a89470)
github.com/microsoft/typescript-go/internal/ls/inlay_hints.go:38 +0x118
github.com/microsoft/typescript-go/internal/lsp.(*Server).handleInlayHint(0x140002a2000?, {0x100d54b48?, 0x140758d8de0?}, 0x1415ec02c60?, 0x90?)
github.com/microsoft/typescript-go/internal/lsp/server.go:973 +0x2c
github.com/microsoft/typescript-go/internal/lsp.init.func1.registerLanguageServiceDocumentRequestHandler[...].27({0x100d54b48, 0x140758d8de0}, 0x14077a894a0)
github.com/microsoft/typescript-go/internal/lsp/server.go:565 +0xe0
github.com/microsoft/typescript-go/internal/lsp.(*Server).handleRequestOrNotification(0x1400021e008, {0x100d54b80?, 0x140774845f0?}, 0x14077a894a0)
github.com/microsoft/typescript-go/internal/lsp/server.go:458 +0x128
github.com/microsoft/typescript-go/internal/lsp.(*Server).dispatchLoop.func1()
github.com/microsoft/typescript-go/internal/lsp/server.go:361 +0x34
created by github.com/microsoft/typescript-go/internal/lsp.(*Server).dispatchLoop in goroutine 4
github.com/microsoft/typescript-go/internal/lsp/server.go:381 +0x7a0
[Error - 8:27:24 PM] Request textDocument/inlayHint failed.
Message: InternalError: panic handling request textDocument/inlayHint: runtime error: slice bounds out of range [20991:20987]
Code: -32603
Steps to reproduce
Relevant vscode settings:
"editor.inlayHints.fontSize": 10,
"editor.inlayHints.padding": true,
"editor.inlineSuggest.enabled": true,
"javascript.inlayHints.functionLikeReturnTypes.enabled": true,
"javascript.inlayHints.parameterNames.enabled": "all",
"javascript.inlayHints.parameterNames.suppressWhenArgumentMatchesName": false,
"javascript.inlayHints.parameterTypes.enabled": true,
"javascript.inlayHints.variableTypes.suppressWhenTypeMatchesName": false,
"json.schemaDownload.enable": true,
"typescript.inlayHints.enumMemberValues.enabled": true,
"typescript.inlayHints.functionLikeReturnTypes.enabled": true,
"typescript.inlayHints.parameterNames.enabled": "all",
"typescript.inlayHints.parameterNames.suppressWhenArgumentMatchesName": false,
"typescript.inlayHints.parameterTypes.enabled": true,
"typescript.inlayHints.variableTypes.suppressWhenTypeMatchesName": false,