Skip to content

mypy: Update tox configuration

Nsukami Patrick requested to merge topic/default/mypy-install-stubs into branch/default

From version 0.900, Mypy now only ships with type stubs for stdlib modules. For some third-party libraries we need to explicitly install stub packages.

See: http://mypy-lang.blogspot.com/2021/06/mypy-0900-released.html

This will also fix the following error:

.tox/mypy/lib/python3.8/site-packages/logilab/common/__init__.py:31: error: Library stubs not installed  
for "pkg_resources" (or incompatible with Python 3.8)  [import]                                          
.tox/mypy/lib/python3.8/site-packages/logilab/common/modutils.py:661: error: Library stubs not           
installed for "pkg_resources" (or incompatible with Python 3.8)  [import]                                
rql/__init__.py:26: error: Library stubs not installed for "pkg_resources" (or incompatible with Python  
3.8)  [import]                                                                                           
rql/__init__.py:26: note: Hint: "python3 -m pip install types-pkg_resources"                             
rql/__init__.py:26: note: (or run "mypy --install-types" to install all missing stub packages)           
rql/__init__.py:26: note: See https://mypy.readthedocs.io/en/stable/running_mypy.html#missing-imports    
Found 3 errors in 3 files (checked 17 source files)

Merge request reports

Loading