Skip to content
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

Fix ParamSpec constraint for types as callable #14153

Merged

Commits on Nov 19, 2022

  1. Fix ParamSpec constraint for types as callable

    Most types can be considered as callables, constructing the type itself.
    When a constraint was created for a ParamSpec variable, the return type
    would be set to NoneType, which conflicts with assumptions that
    CallableType makes when it is the constructor of another type, crashing
    mypy. This patch replaces the return type by UninhabitedType instead,
    which stops CallableType from considering itself as a constructor.
    VincentVanlaer committed Nov 19, 2022
    Configuration menu
    Copy the full SHA
    9773e70 View commit details
    Browse the repository at this point in the history

Commits on Nov 20, 2022

  1. Add --strict-optional flag to testParamSpecClassConstructor

    Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
    VincentVanlaer and hauntsaninja committed Nov 20, 2022
    Configuration menu
    Copy the full SHA
    5ff55dc View commit details
    Browse the repository at this point in the history

Commits on Nov 28, 2022

  1. Configuration menu
    Copy the full SHA
    91e3a35 View commit details
    Browse the repository at this point in the history