typeddjango / pytest-mypy-plugins

pytest plugin for testing mypy types, stubs, and plugins
https://pypi.org/project/pytest-mypy-plugins/
MIT License
100 stars 26 forks source link

Fix compatibility with pytest 7.2 #106

Closed The-Compiler closed 1 year ago

The-Compiler commented 1 year ago

With pytest 7.2, the remaining parts of the "py.path" library got vendored, to get rid of the dependency: https://github.com/pytest-dev/pytest/pull/10396

However, this breaks due to pytest_mypy_plugins importing private API:

File ".../pytest_mypy_plugins/collect.py", line 13, in <module>
    from py._path.local import LocalPath
ModuleNotFoundError: No module named 'py._path'; 'py' is not a package

Use py.path.local instead (the public name of the same type), which is part of the shim included in pytest.

The-Compiler commented 1 year ago

just did so! Looks like you need to kick the CI again.

sobolevn commented 1 year ago

I will make a new release today!