Skip to content

Cancellation token passed to provideReferences is never cancelled #5100

@lukehoban

Description

@lukehoban
  • VSCode Version: 0.10.11
  • OS Version: OS X

The cancellation token passed to vscode.ReferenceProvider#provideReferences appears to not get cancelled ever - and in particular, not get cancelled when the Find References panel is closed by the user.

Since Find References can require an expensive compute operation to be needed, this is particularly unfortunate. In the vscode-go extension, this user command spawns a process which can in pathological cases take more than a minute (and use 100% of multiple cores). A user can easily do Find References multiple times (because they see no results being returned), causing multiple of these processes to be spawned.

Are there any documented semantics for the cancelation token's passed to these higher level language service APIs? Is there some case where the provideReferences cancellation token will actually be cancelled?

Metadata

Metadata

Assignees

Labels

bugIssue identified by VS Code Team member as probable bugverifiedVerification succeeded

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions