Skip to content
This repository has been archived by the owner on Aug 5, 2022. It is now read-only.

Return ServerNotInitialized #31

Merged
merged 1 commit into from Apr 27, 2021

Conversation

kjeremy
Copy link
Contributor

@kjeremy kjeremy commented Apr 25, 2021

According to https://microsoft.github.io/language-server-protocol/specifications/specification-3-17/#initialize
if the server is expecting an initialize request but gets something else
it should return ServerNotInitialized (-32002).

Notifications should be dropped except for exit but that's already
covered by the error path.

Fixes #30

According to https://microsoft.github.io/language-server-protocol/specifications/specification-3-17/#initialize
if the server is expecting an initialize request but gets something else
it should return ServerNotInitialized (-32002).

Notifications should be dropped except for `exit` but that's already
covered by the error path.

Fixes rust-analyzer#30
@kjeremy kjeremy requested a review from matklad April 25, 2021 21:58
@matklad
Copy link
Member

matklad commented Apr 27, 2021

bors r+

@bors
Copy link
Contributor

bors bot commented Apr 27, 2021

Build succeeded:

@bors bors bot merged commit 7bb6dd0 into rust-analyzer:master Apr 27, 2021
@kjeremy kjeremy deleted the server-not-initialized branch April 27, 2021 11:21
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

initialize_start should return ServerNotInitialized to the client if the request is not initialize
2 participants