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

Notification/Requests from Server => Client #33

Closed
tris203 opened this issue Jun 29, 2024 · 1 comment
Closed

Notification/Requests from Server => Client #33

tris203 opened this issue Jun 29, 2024 · 1 comment

Comments

@tris203
Copy link

tris203 commented Jun 29, 2024

Firstly, thanks for this library. It makes implementing a LSP in Go a pleasure and the API is delightful!

Forgive me if I'm wrong, but I think the current implementation is purely re-active. Eg, responding to client requests on the server.

If I look at for example window/ShowMessage or $/progress these are notifications sent to the client from the server.
However they seem to be implemented in the same way as textDocument/didOpen for example.
Which is a request sent from the client.

From this, I believe it is currently impossible to send arbitrary messages from the server to a client, and only to respond to Requests/Act on notifications from the client.

I would be happy to work towards fixing this if this is something you agree with.

Thanks

@tris203
Copy link
Author

tris203 commented Jun 30, 2024

I see now I am mistaken

I can use the Call and Notify methods on the context

Thanks!

@tris203 tris203 closed this as completed Jun 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant