Skip to content

Commit 78f1139

Browse files
Exclude src archives and other non-normal workspace folders
1 parent 935c9b9 commit 78f1139

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

extensions/ql-vscode/src/queries-panel/query-discovery.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ import {
1212
import { MultiFileSystemWatcher } from "../common/vscode/multi-file-system-watcher";
1313
import { App } from "../common/app";
1414
import { FileTreeDirectory, FileTreeLeaf } from "../common/file-tree-nodes";
15+
import { getOnDiskWorkspaceFolders } from "../helpers";
1516

1617
/**
1718
* The results of discovering queries.
@@ -121,7 +122,10 @@ export class QueryDiscovery extends Discovery<QueryDiscoveryResults> {
121122
const name = workspaceFolder.name;
122123

123124
// Don't try discovery on workspace folders that don't exist on the filesystem
124-
if (!(await pathExists(fullPath))) {
125+
if (
126+
!(await pathExists(fullPath)) ||
127+
!getOnDiskWorkspaceFolders().includes(fullPath)
128+
) {
125129
return undefined;
126130
}
127131

0 commit comments

Comments
 (0)