mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-01-08 20:43:25 +08:00
Simplify pyrightconfigs by removing redundant keys (#9293)
This commit is contained in:
@@ -3,54 +3,44 @@
|
||||
"typeshedPath": ".",
|
||||
"include": [
|
||||
"stdlib",
|
||||
"stubs"
|
||||
"stubs",
|
||||
],
|
||||
"exclude": [
|
||||
// `cryptography` stubs are outdated and to be removed
|
||||
"stubs/cryptography"
|
||||
"stubs/cryptography",
|
||||
],
|
||||
"typeCheckingMode": "basic",
|
||||
"strictListInference": true,
|
||||
"strictDictionaryInference": true,
|
||||
"strictParameterNoneValue": true,
|
||||
"strictSetInference": true,
|
||||
"reportFunctionMemberAccess": "error",
|
||||
"reportMissingModuleSource": "none",
|
||||
"reportMissingTypeStubs": "error",
|
||||
"reportUnusedImport": "error",
|
||||
"reportUnusedClass": "error",
|
||||
"reportUnusedFunction": "error",
|
||||
"reportUnusedVariable": "error",
|
||||
"reportDuplicateImport": "error",
|
||||
"reportOptionalSubscript": "error",
|
||||
"reportOptionalMemberAccess": "error",
|
||||
"reportOptionalCall": "error",
|
||||
"reportOptionalIterable": "error",
|
||||
"reportOptionalContextManager": "error",
|
||||
"reportOptionalOperand": "error",
|
||||
"reportUntypedFunctionDecorator": "error",
|
||||
"reportUntypedClassDecorator": "error",
|
||||
"reportUntypedBaseClass": "error",
|
||||
"reportUntypedNamedTuple": "error",
|
||||
"reportPrivateUsage": "none",
|
||||
"reportConstantRedefinition": "error",
|
||||
"reportInvalidStringEscapeSequence": "error",
|
||||
"reportUnknownArgumentType": "error",
|
||||
"reportUnknownLambdaType": "error",
|
||||
"reportMissingTypeArgument": "error",
|
||||
"reportUndefinedVariable": "error",
|
||||
"reportUnboundVariable": "error",
|
||||
"reportInvalidStubStatement": "error",
|
||||
"reportInvalidTypeVarUse": "error",
|
||||
"reportUnsupportedDunderAll": "error",
|
||||
"reportInconsistentConstructor": "error",
|
||||
"reportTypeCommentUsage": "error",
|
||||
"reportUnnecessaryComparison": "error",
|
||||
"reportMissingModuleSource": "none",
|
||||
// Incompatible overrides and property type mismatches are out of typeshed's control
|
||||
// as they are inherited from the implementation.
|
||||
"reportPropertyTypeMismatch": "none",
|
||||
"reportIncompatibleMethodOverride": "none",
|
||||
"reportIncompatibleVariableOverride": "none",
|
||||
"reportPropertyTypeMismatch": "none",
|
||||
// Overlapping overloads are often necessary in a stub, meaning pyright's check
|
||||
// (which is stricter than mypy's; see mypy issue #10143 and #10157)
|
||||
// would cause many false positives and catch few bugs.
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
"typeshedPath": ".",
|
||||
"include": [
|
||||
"stdlib",
|
||||
"stubs"
|
||||
"stubs",
|
||||
],
|
||||
"exclude": [
|
||||
"stdlib/distutils/command",
|
||||
@@ -70,49 +70,12 @@
|
||||
"stubs/tqdm",
|
||||
"stubs/ttkthemes",
|
||||
"stubs/urllib3",
|
||||
"stubs/vobject"
|
||||
"stubs/vobject",
|
||||
],
|
||||
"typeCheckingMode": "basic",
|
||||
"strictListInference": true,
|
||||
"strictDictionaryInference": true,
|
||||
"strictParameterNoneValue": true,
|
||||
"strictSetInference": true,
|
||||
"reportFunctionMemberAccess": "error",
|
||||
"reportMissingModuleSource": "none",
|
||||
"reportMissingParameterType": "error",
|
||||
"reportMissingTypeStubs": "error",
|
||||
"reportUnusedImport": "error",
|
||||
"reportUnusedClass": "error",
|
||||
"reportUnusedFunction": "error",
|
||||
"reportUnusedVariable": "error",
|
||||
"reportDuplicateImport": "error",
|
||||
"reportOptionalSubscript": "error",
|
||||
"reportOptionalMemberAccess": "error",
|
||||
"reportOptionalCall": "error",
|
||||
"reportOptionalIterable": "error",
|
||||
"reportOptionalContextManager": "error",
|
||||
"reportOptionalOperand": "error",
|
||||
"reportUntypedFunctionDecorator": "error",
|
||||
"reportUntypedClassDecorator": "error",
|
||||
"reportUntypedBaseClass": "error",
|
||||
"reportUntypedNamedTuple": "error",
|
||||
"typeCheckingMode": "strict",
|
||||
"reportPrivateUsage": "none",
|
||||
"reportConstantRedefinition": "error",
|
||||
"reportInvalidStringEscapeSequence": "error",
|
||||
"reportUnknownParameterType": "error",
|
||||
"reportUnknownArgumentType": "error",
|
||||
"reportUnknownLambdaType": "error",
|
||||
"reportUnknownVariableType": "error",
|
||||
"reportUnknownMemberType": "error",
|
||||
"reportMissingTypeArgument": "error",
|
||||
"reportUndefinedVariable": "error",
|
||||
"reportUnboundVariable": "error",
|
||||
"reportInvalidStubStatement": "error",
|
||||
"reportInvalidTypeVarUse": "error",
|
||||
"reportUnsupportedDunderAll": "error",
|
||||
"reportInconsistentConstructor": "error",
|
||||
"reportTypeCommentUsage": "error",
|
||||
"reportUnnecessaryComparison": "error",
|
||||
"reportIncompleteStub": "none",
|
||||
"reportMissingModuleSource": "none",
|
||||
// Incompatible overrides and property type mismatches are out of typeshed's control
|
||||
// as they are inherited from the implementation.
|
||||
"reportIncompatibleMethodOverride": "none",
|
||||
|
||||
@@ -2,50 +2,15 @@
|
||||
"$schema": "https://raw.githubusercontent.com/microsoft/pyright/main/packages/vscode-pyright/schemas/pyrightconfig.schema.json",
|
||||
"typeshedPath": ".",
|
||||
"include": [
|
||||
"test_cases"
|
||||
"test_cases",
|
||||
],
|
||||
"typeCheckingMode": "basic",
|
||||
"strictListInference": true,
|
||||
"strictDictionaryInference": true,
|
||||
"strictParameterNoneValue": true,
|
||||
"reportFunctionMemberAccess": "error",
|
||||
"reportMissingModuleSource": "none",
|
||||
"reportMissingTypeStubs": "error",
|
||||
"reportUnusedImport": "error",
|
||||
"reportUnusedClass": "error",
|
||||
"reportUnusedFunction": "error",
|
||||
"reportUnusedVariable": "error",
|
||||
"reportDuplicateImport": "error",
|
||||
"reportOptionalSubscript": "error",
|
||||
"reportOptionalMemberAccess": "error",
|
||||
"reportOptionalCall": "error",
|
||||
"reportOptionalIterable": "error",
|
||||
"reportOptionalContextManager": "error",
|
||||
"reportOptionalOperand": "error",
|
||||
"reportUntypedFunctionDecorator": "error",
|
||||
"reportUntypedClassDecorator": "error",
|
||||
"reportUntypedBaseClass": "error",
|
||||
"reportUntypedNamedTuple": "error",
|
||||
"reportPrivateUsage": "none",
|
||||
"reportConstantRedefinition": "error",
|
||||
"reportInvalidStringEscapeSequence": "error",
|
||||
"reportUnknownParameterType": "error",
|
||||
"reportUnknownArgumentType": "error",
|
||||
"reportUnknownLambdaType": "error",
|
||||
"reportUnknownVariableType": "error",
|
||||
"reportUnknownMemberType": "error",
|
||||
"reportMissingTypeArgument": "error",
|
||||
"reportUndefinedVariable": "error",
|
||||
"reportUnboundVariable": "error",
|
||||
"reportInvalidStubStatement": "error",
|
||||
"reportInvalidTypeVarUse": "error",
|
||||
"typeCheckingMode": "strict",
|
||||
"reportPropertyTypeMismatch": "error",
|
||||
"reportSelfClsParameterName": "error",
|
||||
"reportUnsupportedDunderAll": "error",
|
||||
"reportIncompatibleMethodOverride": "error",
|
||||
"reportIncompatibleVariableOverride": "error",
|
||||
"reportOverlappingOverload": "error",
|
||||
"reportUnnecessaryTypeIgnoreComment": "error",
|
||||
"reportMissingTypeStubs": "error",
|
||||
"reportMatchNotExhaustive": "error"
|
||||
"reportMissingModuleSource": "none",
|
||||
"reportPrivateUsage": "none",
|
||||
// isinstance checks are still needed when validating inputs outside of typeshed's control
|
||||
"reportUnnecessaryIsInstance": "none",
|
||||
// The name of the self/cls parameter is out of typeshed's control.
|
||||
"reportSelfClsParameterName": "none",
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user