Skip to content

Panic: unimplemented request: workspace/semanticTokens/refresh #125

Open
@kittaakos

Description

@kittaakos

Describe the problem

I am playing with the LS to support multiple running language servers per workspace.

I see the following error:

Panic: unimplemented request: workspace/semanticTokens/refresh

goroutine 22 [running]:
runtime/debug.Stack()
	/usr/local/go/src/runtime/debug/stack.go:24 +0x65
github.com/arduino/arduino-language-server/streams.CatchAndLogPanic()
	/home/build/streams/panics.go:14 +0x74
panic({0x4634b40, 0xc00030b770})
	/usr/local/go/src/runtime/panic.go:838 +0x207
go.bug.st/lsp.(*Client).requestDispatcher(0xc000432090, {0x4849750, 0xc00028cac0}, {0x4844020, 0xc00000eaf8}, {0xc000042f80, 0x20}, {0xc00028f088, 0x4, 0x8}, ...)
	/go/pkg/mod/go.bug.st/[email protected]/client.go:199 +0x9fd
go.bug.st/lsp/jsonrpc.(*Connection).handleIncomingRequest(0xc000174000, 0xc000254dc0)
	/go/pkg/mod/go.bug.st/[email protected]/jsonrpc/jsonrpc_connection.go:153 +0x2bb
go.bug.st/lsp/jsonrpc.(*Connection).handleIncomingData(0xc000174000, {0xc000041740, 0x52, 0x52})
	/go/pkg/mod/go.bug.st/[email protected]/jsonrpc/jsonrpc_connection.go:128 +0x167
go.bug.st/lsp/jsonrpc.(*Connection).Run(0xc000174000)
	/go/pkg/mod/go.bug.st/[email protected]/jsonrpc/jsonrpc_connection.go:119 +0x98
go.bug.st/lsp.(*Client).Run(...)
	/go/pkg/mod/go.bug.st/[email protected]/client.go:83
github.com/arduino/arduino-language-server/ls.(*ClangdLSPClient).Run(...)
	/home/build/ls/lsp_client_clangd.go:86
github.com/arduino/arduino-language-server/ls.(*INOLanguageServer).InitializeReqFromIDE.func1.1()
	/home/build/ls/ls.go:201 +0x5b
created by github.com/arduino/arduino-language-server/ls.(*INOLanguageServer).InitializeReqFromIDE.func1
	/home/build/ls/ls.go:199 +0x4b0

panic: unimplemented request: workspace/semanticTokens/refresh [recovered]
	panic: unimplemented request: workspace/semanticTokens/refresh

goroutine 22 [running]:
github.com/arduino/arduino-language-server/streams.CatchAndLogPanic()
	/home/build/streams/panics.go:15 +0x145
panic({0x4634b40, 0xc00030b770})
	/usr/local/go/src/runtime/panic.go:838 +0x207
go.bug.st/lsp.(*Client).requestDispatcher(0xc000432090, {0x4849750, 0xc00028cac0}, {0x4844020, 0xc00000eaf8}, {0xc000042f80, 0x20}, {0xc00028f088, 0x4, 0x8}, ...)
	/go/pkg/mod/go.bug.st/[email protected]/client.go:199 +0x9fd
go.bug.st/lsp/jsonrpc.(*Connection).handleIncomingRequest(0xc000174000, 0xc000254dc0)
	/go/pkg/mod/go.bug.st/[email protected]/jsonrpc/jsonrpc_connection.go:153 +0x2bb
go.bug.st/lsp/jsonrpc.(*Connection).handleIncomingData(0xc000174000, {0xc000041740, 0x52, 0x52})
	/go/pkg/mod/go.bug.st/[email protected]/jsonrpc/jsonrpc_connection.go:128 +0x167
go.bug.st/lsp/jsonrpc.(*Connection).Run(0xc000174000)
	/go/pkg/mod/go.bug.st/[email protected]/jsonrpc/jsonrpc_connection.go:119 +0x98
go.bug.st/lsp.(*Client).Run(...)
	/go/pkg/mod/go.bug.st/[email protected]/client.go:83
github.com/arduino/arduino-language-server/ls.(*ClangdLSPClient).Run(...)
	/home/build/ls/lsp_client_clangd.go:86
github.com/arduino/arduino-language-server/ls.(*INOLanguageServer).InitializeReqFromIDE.func1.1()
	/home/build/ls/ls.go:201 +0x5b
created by github.com/arduino/arduino-language-server/ls.(*INOLanguageServer).InitializeReqFromIDE.func1
	/home/build/ls/ls.go:199 +0x4b0

To reproduce

Install the VS Code extension from my fork: https://github.com/kittaakos/vscode-arduino-tools/tree/multi-ls-support/build-artifacts

  • Start VS Code,
  • Open the sketchbook (assuming it contains more than one sketches) sketch

Expected behavior

It does not throw.

Arduino Language Server version

0.7.1

Arduino CLI version

0.25.0

Operating system

macOS

Operating system version

12.3.1

Additional context

No response

Issue checklist

  • I searched for previous reports in the issue tracker
  • I verified the problem still occurs when using the latest version
  • My report contains all necessary details

Metadata

Metadata

Assignees

No one assigned

    Labels

    topic: codeRelated to content of the project itselftype: imperfectionPerceived defect in any part of project

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions