Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork3.1k
Open
Description
Bug Report
mypy should useList when surfacing errors with theList type, notlist.
It's confusing to engineers ifmypy useslist when complaining about a type error because then engineers aresearching the source code for occurrences oflist, when the problem is actually with the usage ofList.
To Reproduce
self.orders:typing.List[typing.List[int,int]]= []
Expected Behavior
mypy should complain with
error: "List" expects 1 type argument, but 2 given [type-arg]Actual Behavior
mypy actually complains with
error: "list" expects 1 type argument, but 2 given [type-arg]Your Environment
- Mypy version used:
mypy==1.10.0 - Mypy command-line flags: n/a
- Mypy configuration options from
mypy.ini(and other config files): n/a - Python version used:
Python 3.10.12