Skip to content

Commit 25a3c0c

Browse files
committed
Improve basedpyright configuration for root-level scripts
- Add *.py to include patterns for root-level Python scripts - Add executionEnvironments with extraPaths for better import resolution - Fixes false positive import error in start_local_server.py This ensures basedpyright can resolve imports in scripts that use runtime path manipulation (sys.path.insert).
1 parent 7dbece9 commit 25a3c0c

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

.basedpyright.json

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,19 @@
11
{
2-
"include": ["src"],
2+
"include": ["src", "*.py"],
33
"exclude": ["tests/**", "**/__pycache__", ".venv/**", "build/**", "dist/**"],
44
"typeCheckingMode": "strict",
55
"reportMissingTypeStubs": false,
66
"reportUnknownVariableType": false,
77
"pythonVersion": "3.12",
88
"pythonPlatform": "All",
9-
"extraPaths": ["src"]
9+
"extraPaths": ["src"],
10+
"executionEnvironments": [
11+
{
12+
"root": ".",
13+
"pythonVersion": "3.12",
14+
"pythonPlatform": "All",
15+
"extraPaths": ["src"]
16+
}
17+
]
1018
}
1119

0 commit comments

Comments
 (0)