Skip to content

Commit 1c16fd1

Browse files
authored
Merge pull request #4256 from github/copilot/fix-github-actions-workflow
Fix race condition in language client visibility notifications
2 parents e39a32a + 4039b4f commit 1c16fd1

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

extensions/ql-vscode/src/language-support/language-client.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,10 @@ export class CodeQLLanguageClient extends LanguageClient {
4545
}
4646

4747
notifyVisibilityChange(editors: readonly TextEditor[]) {
48+
// Only send notification if the language client is running to avoid race conditions
49+
if (!this.isRunning()) {
50+
return;
51+
}
4852
const files = editors
4953
.filter((e) => e.document.uri.scheme === "file")
5054
.map((e) => e.document.uri.toString());

0 commit comments

Comments
 (0)