Bug Report
Since updating numpy from version "1.20.3" to version "1.21.0" we are getting the following errors:
error: Call to untyped function "load" in typed context
We want to suppress errors about untyped calls from numpy - but not globally.
To Reproduce
(Write your steps here:)
- files
mypy.ini:
[mypy]
disallow_untyped_calls = True
[mypy-numpy.*]
disallow_untyped_calls = False
example.py:
import numpy as np
def fun() -> None:
np.save("path", [1, 2])
- Call with:
mypy example.py --config-file mypy.ini
Expected Behavior
Expected to not see an error about: Call to untyped function
Actual Behavior
Actual: example.py:5: error: Call to untyped function "save" in typed context
Your Environment
- Mypy version used:
mypy 0.812
- Mypy command-line flags:
--config-file mypy.ini
- Mypy configuration options from
mypy.ini (and other config files):
- Python version used:
Python 3.8.10
- Operating system and version:
Ubuntu 20.04.2 LTS
- Numpy version:
1.21.0
Note: setting disallow_untyped_calls to False globally does work (but is undesired)
Bug Report
Since updating numpy from version "1.20.3" to version "1.21.0" we are getting the following errors:
error: Call to untyped function "load" in typed contextWe want to suppress errors about untyped calls from numpy - but not globally.
To Reproduce
(Write your steps here:)
mypy.ini:example.py:mypy example.py --config-file mypy.iniExpected Behavior
Expected to not see an error about:
Call to untyped functionActual Behavior
Actual:
example.py:5: error: Call to untyped function "save" in typed contextYour Environment
mypy 0.812--config-file mypy.inimypy.ini(and other config files):Python 3.8.10Ubuntu 20.04.2 LTS1.21.0Note: setting
disallow_untyped_callsto False globally does work (but is undesired)