Detect incompatibile mypy version and print a warning #1793
Labels
enhancement
New feature or request
help wanted
Extra attention is needed
mypy-plugin
Issues specific to mypy_django_plugin
Every now and then, users report issues when using the
django-stubs
mypy plugin with old mypy versions that are not compatible, which may be due to being unaware of the coupling between these packages, or just by mistake. E.g. #1784, #1434.Mypy's plugin API has been pretty stable recently, but it still happens occasionally that we introduce dependency on new mypy features or APIs that breaks older mypy, e.g. #1703
So to save developer time as well as users' time, we should consider issuing a warning or error message, to make debugging this easier.
Of course there's a balance to be struck here. In my projects, I often upgrade mypy out of sync with
django-stubs
's officialcompatible-mypy
; mypy's version is sometimes one major version ahead or behindcompatible-mypy
. And I think we shouldn't prevent that use case.The text was updated successfully, but these errors were encountered: