microsoft / microsoft/language-server-protocol

Question regarding ordering for rename requests

Open
#1,663 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

clarification rename
Dominant language
TypeScript
Stars
13k
Forks
1k
Avg merge
6d 1h
Merged PRs (30d)
10

Description

I am developing a new language server and I'm having issues understanding how multiple rename requests should be handled and in which order.

Suppose the client sends a rename request and the server starts computing the results, while it's computing, the client sends another rename request, in this case, what should do the server do?

  • Should it try to fullfill the first rename request and then process the second request such that the requests are queued at the server?
  • Should the request be cancelled? In tha case: Who should cancel the request? and which of the two request should be cancelled?

Note that the same questions can be asked about all requests that send a WorkspaceEdit as a result.

Contributor guide

No contributing guide indexed for this repository

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.

Research direction

No file, test, or entry point is named in the issue. Start by reviewing the language server protocol's request-cancellation and WorkspaceEdit guidance, then clarify the expected ordering or cancellation behavior for overlapping rename requests and whether the same rule applies to other WorkspaceEdit-producing requests.

Written by the indexing model from the issue text.

Assessment

Domain
api
Issue type
Documentation
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.