8000 Switch from `mypy` to `pyright` · Issue #120 · ZettaAI/zetta_utils · GitHub
[go: up one dir, main page]

Skip to content
Switch from mypy to pyright #120
@supersergiy

Description

@supersergiy

mypy is buggy with ParamSpecs which forces us to insert type-ignore pragmas in certain scenarios.
pyright is faster, less buggy, and gives more helpful error messages. However it doesn't support custom plugings, so some of the mazepa decorators would have to be retyped. pyright design doesn't allow us to add custom decorators on top of attrs(init=True), so all of the flow schema classes and taskable operation classes would have to have custom __init__'s. pyright doesn't support bounding a TypeVar by a Union, so some @overload's would have to be added, specifically in the tensor_ops module. Lastly, some type stub modifications would need to be done for torch and pytorch_lightning, and possibly numpy.

mypy bug trackers:

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0