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

Unable to use plugins in 0.920 #11772

Closed
Apakottur opened this issue Dec 16, 2021 · 2 comments
Closed

Unable to use plugins in 0.920 #11772

Apakottur opened this issue Dec 16, 2021 · 2 comments
Labels
bug mypy got something wrong

Comments

@Apakottur
Copy link

Bug Report

I am using mypy plugins for libraries like pydantic and SQLAlchemy.

Attempting to upgrade mypy from 0.910 to 0.920 breaks when using any of those plugins.

To Reproduce

Create the two following files:

# test.py
def func(var: int) -> int:
    return var
# mypy.ini
[mypy]
plugins=pydantic.mypy

Install pydantic and mypy, and run mypy --config mypy.ini test.py

Expected Behavior

No issues are found.

Actual Behavior

I am getting the following error:

mypy.ini:2: error: Error importing plugin "pydantic.mypy": cannot import name 'TypeVarDef' from 'mypy.types' (***/python3.10/site-packages/mypy/types.cpython-310-x86_64-linux-gnu.so)
Found 1 error in 1 file (errors prevented further checking)

Your Environment

  • Mypy version used: 0.920
  • Python version used: 3.10.1
@Apakottur Apakottur added the bug mypy got something wrong label Dec 16, 2021
@arnimarj
Copy link

An issue has been created for pydantic: pydantic/pydantic#3528

@Apakottur
Copy link
Author

Awesome, closing this one then.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug mypy got something wrong
Projects
None yet
Development

No branches or pull requests

2 participants