Skip to content

showTextDocument returned the wrong editor when called multiple times concurrently #134786

Closed
@DanTup

Description

It seems like there may be some race condition in showTextDocument where if it's called multiple times before the previous has completed, each call returns the last editor to be opened.

Here I have an array of two items short_test.dart and short2_test.dart and I call openTextDocument and showTextDocument for each. However the resulting editors both point at short2_test.dart:

Screenshot 2021-10-11 at 12 15 52

The results from openTextDocument are correct in both cases, it's only showTextDocument that seems to be misbehaving.

Metadata

Assignees

Labels

apiauthor-verification-requestedIssues potentially verifiable by issue authorbugIssue identified by VS Code Team member as probable buginsiders-releasedPatch has been released in VS Code InsidersverifiedVerification succeededworkbench-editorsManaging of editor widgets in workbench window

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions