Bug Report
Dmypy ignores follow_imports=skip override on the second run.
To Reproduce
import IPython.terminal.prompts
reveal_type(IPython)
reveal_type(IPython.terminal.prompts)
pyproject.toml:
[tool.mypy]
python_version = "3.10"
follow_imports = "normal"
[[tool.mypy.overrides]]
module = [
"IPython.terminal.prompts",
]
follow_imports = "skip"
Expected Behavior
All runs of dmypy run bar.py will show the same output:
bar.py:4: note: Revealed type is "types.ModuleType"
bar.py:5: note: Revealed type is "Any"
Actual Behavior
The first run of dmypy run bar.py shows:
bar.py:4: note: Revealed type is "types.ModuleType"
bar.py:5: note: Revealed type is "Any"
The second run of dmypy run bar.py shows:
bar.py:4: note: Revealed type is "types.ModuleType"
bar.py:5: note: Revealed type is "types.ModuleType"
Running mypy bar.py works correctly every time.
Your Environment
- Mypy version used: mypy 1.4.0
- Mypy command-line flags:
- Mypy configuration options from
mypy.ini (and other config files):
- Python version used: Python 3.10.12
Bug Report
Dmypy ignores
follow_imports=skipoverride on the second run.To Reproduce
pyproject.toml:
Expected Behavior
All runs of
dmypy run bar.pywill show the same output:Actual Behavior
The first run of
dmypy run bar.pyshows:The second run of
dmypy run bar.pyshows:Running
mypy bar.pyworks correctly every time.Your Environment
mypy.ini(and other config files):