Skip to content

Running mypy --strict, list with no type arguments gets the wrong error message with parameters instead of arguments #20493

@hyperkai

Description

@hyperkai

*Memo:

  • mypy --strict test.py
  • mypy 1.19.1
  • Python 3.14
  • Windows 11

Running mypy --strict, list with no type arguments gets the wrong error message with parameters instead of arguments as shown below:

v: list = [0, 1, 2]

error: Missing type parameters for generic type "list"

So, the error message should be with arguments instead of parameters as shown below:

error: Missing type arguments for generic type "list"

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugmypy got something wrong

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions