Closed
Description
Bug Report
Inspired by #18530, I tried using --pretty
on a file with [type-arg]
. Unfortunately the output isn't immediately understandable.
To Reproduce
import typing
x: typing.List[typing.List[int, int]] = []
Expected Behavior
repro.py:3: error: "list" expects 1 type argument, but 2 given [type-arg]
x: typing.List[typing.List[int, int]] = []
^~~~~~~~~~~~~~~~~~~~~
Found 1 error in 1 file (checked 1 source file)
Actual Behavior
repro.py:3: error: "list" expects 1 type argument, but 2 given [type-arg]
x: typing.List[typing.List[int, int]] = []
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Found 1 error in 1 file (checked 1 source file)
Your Environment
- Mypy version used: v1.14.1
- Mypy command-line flags:
--warn-unreachable
- Mypy configuration options from
mypy.ini
(and other config files): none, I think - Python version used: 3.13.1