vshaxe icon indicating copy to clipboard operation
vshaxe copied to clipboard

haxe-language-server doesn't work until the first onDidChangeConfiguration event

Open joshtynjala opened this issue 6 years ago • 6 comments

This is a request to document in the readme that there's a requirement to send a didChangeConfiguration notification as part of initializing the Haxe language server.

Making the notification optional would also be fine.

I ran into this issue trying to get the Haxe language server working in Moonshine IDE. Everything seemed to work up through the initialized notification, and then the language server didn't accept any further requests, like hover, definition or completion.

Luckily, I'm the one who implemented the client side of the protocol in Moonshine, so I can ensure that this notification is always sent. In my initial tests, adding this notification after init doesn't seem to hurt any existing language servers that I've previously integrated that worked fine without it.

joshtynjala avatar Jun 19 '19 20:06 joshtynjala

I think it's actually part of the LSP spec that there's an initial onDidChangeConfiguration?

Gama11 avatar Jun 19 '19 20:06 Gama11

@Gama11 I'm not seeing that mentioned in the spec...

joshtynjala avatar Jun 19 '19 20:06 joshtynjala

I might be wrong, but then we should actually change this as it would be a violation of the spec, not document it. I think other language clients actually struggled with this too.

Gama11 avatar Jun 19 '19 20:06 Gama11

Yeah, I figured out that this notification was needed based on the comments in #171 and #328 related to Neovim and Sublime.

joshtynjala avatar Jun 19 '19 20:06 joshtynjala

I ran into this as well, it required a lot of debugging and code tracing to figure out what was going wrong.

jdonaldson avatar Aug 21 '19 23:08 jdonaldson