Closed ZeeD closed 2 years ago
Is it a "bug" (a missing implementation?) of lsp4j?
No, it is not a bug in LSP4J.
Looks like the language server sends the workspace/configuration
request to LSP4E, but LSP4E does not provide the workspace.configuration
capability:
So, it seems to be a bug in the language server, since it should not send the request to a language client that does not support it.
OK. Sorry for the noise: I though that lsp4e was just a wrapper of lsp4j (that should support "workspace/configuration", correct?) but it seems it added additional requirements.
To clarify it a little bit, LSP4E is a language client implementation for Eclipse, which uses LSP4J to communicate with a language server.
It is up to a language client whether it supports requests such as workspace/configuration
. If the language client opts to support such a request, it should be signaled to the language server via a client capability (workspace.configuration
in this case). If the language client does not provide such a capability, the language server should not send the corresponding request to the client.
Since LSP4E opted not to provide the workspace.configuration
capability, it would be a bug in a language server to send the workspace/configuration
request to LSP4E. Although LSP4E could potentially be enhanced to support this request, this is not a requirement of the LSP spec. However, the specification requires that the server should not send the request if the client does not support it.
That's why I think this is a bug in the language server you are using.
HTH
Clear FYI I contacted the brs team and updated the server implementation to avoid sending the workspace/configuration request
Great! Thanks @ZeeD for the information.
Hi (sorry if it's not the right place, I hope I got it right)
There is a vscode extension (BrightScript Language) that, among other things, implements an LSP. My understanding is that the main logic is here, so I tough it would be possible to extract as a stand-alone script.
I have written a simple wrapper (basically it's just the following code)
and integrated into eclipse (I'm using WWD, so via gui I created a new launch configuration, and assigned it via Preferences -> "Languages servers"). I can see that the script starts. Unfortunately it seems to crash. The logs (below) seems to indicate that the server requires to the client to do an "workspace/configuration" operation, and the client... doesn't seem to understand.
Is it a "bug" (a missing implementation?) of lsp4j?