microsoft / microsoft/TypeScript

tsserver protocol is missing notification message type. (maybe?)

Open
#37,821 4 comments 0 reactions 1 assignee View on GitHub

@sheetalkamat is already working on this.

Since Jun 1, 2020.

Needs Investigation
Dominant language
Go
Stars
111k
Forks
14.3k
Avg merge
2d 4h
Merged PRs (30d)
132

Description

While implementing a tsserver client, I found out not all request messages will reply with a response.
For example, the open request extends the Request interface. But it really notifies (as the documentation implies).
This was a bit confusing for me, because I understood that if I send an open request, I must wait for the response... but it never came.
https://github.com/microsoft/TypeScript/blob/a2609b1f1b58f9b6ef62cb3b6ff47efb35059eee/lib/protocol.d.ts#L1113-L1124

I understand that the interface documentation says the server will not send a response. I didn't read the full command documentation until now.
But maybe the documentation could be a bit more explicit about a kind of message where a response is not expected, for certain commands (maybe notify?).

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.