-
-
Notifications
You must be signed in to change notification settings - Fork 28
Expand file tree
/
Copy pathpyrightconfig.json
More file actions
53 lines (50 loc) · 1.58 KB
/
Copy pathpyrightconfig.json
File metadata and controls
53 lines (50 loc) · 1.58 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
// https://github.com/microsoft/pyright/blob/main/docs/configuration.md//sample-config-file
{
"typeCheckingMode": "strict",
// Prefer `pyright: ignore`
"enableTypeIgnoreComments": false,
/**
* Downgraded diagnostics
*/
// Type stubs may not be completable
"reportMissingTypeStubs": "warning",
// Extra runtime safety
"reportUnnecessaryComparison": "warning",
// Using Ruff instead. Name is already grayed out and red squiggle looks like a mistyped import
"reportUnusedImport": "none",
/**
* Off by default even in strict mode
*/
"deprecateTypingAliases": true,
"enableExperimentalFeatures": true,
"reportCallInDefaultInitializer": "error",
"reportImplicitOverride": "error",
"reportImplicitStringConcatenation": "error",
// False positives with TYPE_CHECKING, mostly covered by Ruff TCH00
"reportImportCycles": "none",
// Too strict. False positives on base classes
"reportMissingSuperCall": "none",
"reportPropertyTypeMismatch": "error",
"reportUninitializedInstanceVariable": "error",
"reportUnnecessaryTypeIgnoreComment": "error",
"reportUnusedCallResult": "none",
// Exclude from scanning when running pyright
"exclude": [
// mypyc build folder
"build/",
// PyInstaller dist folder
"dist/",
// Auto generated, fails some strict pyright checks
"src/gen/",
// Defaults
"**/.*",
"**/__pycache__",
"**/node_modules",
".venv",
],
// Ignore must be specified for Pylance to stop displaying errors
"ignore": [
// We expect stub files to be incomplete or contain useless statements
"**/*.pyi",
],
}