Skip to content

TYP: Track progress of pyright rules #43742

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
32 tasks
twoertwein opened this issue Sep 25, 2021 · 1 comment
Closed
32 tasks

TYP: Track progress of pyright rules #43742

twoertwein opened this issue Sep 25, 2021 · 1 comment
Labels
Enhancement Typing type annotations, mypy/pyright type checking

Comments

@twoertwein
Copy link
Member

twoertwein commented Sep 25, 2021

Pyright has many rules, but currently most of them are disabled.

Here is a list of all currently disabled rules and in bracket the number of violations (grep -c) to have a rough idea how much effort enabling a certain rule is:

"Core" Typing:

  • reportGeneralTypeIssues (2322)
  • reportFunctionMemberAccess (5)
  • reportIncompatibleMethodOverride (313)
  • reportIncompatibleVariableOverride (11)
  • reportMissingTypeArgument (369)
  • reportOptionalCall (8)
  • reportOptionalIterable (6)
  • reportOptionalMemberAccess (478)
  • reportOptionalOperand (7)
  • reportOptionalSubscript (34)
  • reportPropertyTypeMismatch (1)

Third-Party/Conventions/Other:

  • reportConstantRedefinition (21)
  • reportImportCycles (40)
  • reportMissingModuleSource (2)
  • reportMissingTypeStubs (102)
  • reportPrivateImportUsage (3)
  • reportPrivateUsage (765)
  • reportUnboundVariable (70)
  • reportUnknownArgumentType (11458)
  • reportUnknownLambdaType (304)
  • reportUnknownMemberType (21661)
  • reportUnknownParameterType (10035)
  • reportUnknownVariableType (12947)
  • reportUnnecessaryComparison (35)
  • reportUnnecessaryIsInstance (86)
  • reportUnsupportedDunderAll (1)
  • reportUntypedBaseClass (18)
  • reportUntypedFunctionDecorator (3)
  • reportUnusedClass (2): used for compatibility in pickle
  • reportUnusedFunction (6): needs a discussion whether these private functions should either be moved or made public
  • reportUnusedImport (292): could be enabled if __all__ or redundant import were used
  • reportUnusedVariable (67): needs consensus to start unused variables with _.
@twoertwein twoertwein added Enhancement Needs Triage Issue that has not been reviewed by a pandas team member labels Sep 25, 2021
@lithomas1 lithomas1 added Typing type annotations, mypy/pyright type checking and removed Needs Triage Issue that has not been reviewed by a pandas team member labels Sep 26, 2021
@twoertwein
Copy link
Member Author

Closing this issue as it is not actionable.

The key goal is to enable reportGeneralTypeIssues which we will hopefully slowly achieve once more of the pandas code base is typed (especially the return values).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement Typing type annotations, mypy/pyright type checking
Projects
None yet
Development

No branches or pull requests

2 participants