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

[LSP] Hover sometimes illegaly returns contents: [null, null] #1087

Closed
mickaelistria opened this issue Jan 12, 2018 · 6 comments
Closed

[LSP] Hover sometimes illegaly returns contents: [null, null] #1087

mickaelistria opened this issue Jan 12, 2018 · 6 comments
Labels

Comments

@mickaelistria
Copy link

In some circumstances not yet identified, the LSP support returns {"protocolVersion":"2.0","id":"2","result":{"contents":[null,null]}}. This value doesn't seem conform to the protocol which doesn't make any of the value nullable or optional here. As a consequence the parser in LSP4J api fails at parsing the stream and closes it to handle the error, cascading to a restart of the LS and so on.
While LSP4J has a part of responsibility, it's somehow fair to assume that the messages sent conform to specification. In the case of contents:[null,null], it would be better to simply return contents:[].

@slimsag
Copy link

slimsag commented Jun 15, 2018

I just ran into this issue as well with a different LSP client, just wanted to mention it :)

@mickaelistria
Copy link
Author

This is really happening quite often even with latest version of OmniSharp and it results in error in some clients. Is there a way this could be fixed soon?
According to https://microsoft.github.io/language-server-protocol/specification , in this case,

{"protocolVersion":"2.0","id":"2","result":null}

would be a better error message.

@mickaelistria
Copy link
Author

I cannot reproduce it with latest snapshot (includes more recent OmniSharp version)

@rcjsuen
Copy link

rcjsuen commented Jul 24, 2019

I'm still seeing this withomnisharp-mono.tar.gz on v1.34.0. It was originally reported by two other users from TypeFox/monaco-languageclient#146.

@tomv564
Copy link

tomv564 commented Aug 26, 2019

Still seeing this as well from the Sublime Text LSP package on version v1.34.2.

@easbarba
Copy link

easbarba commented Dec 22, 2019

Issue still happening in 1.34.9: joaotavora/eglot#371 (comment)

log: http://ix.io/253F/text - lines: 3177 and 3555

full reporting: joaotavora/eglot#371 (comment)

related: emacs-lsp/lsp-ui#350

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

6 participants