-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Closed
Description
- Are you reporting a bug, or opening a feature request?
A Bug maybe?
- Please insert below the code you are checking with mypy
test.py
:
from typing import Sequence, List
class A:
def test(self, t: Sequence[int]) -> Sequence[str]:
pass
class B(A):
def test(self, t: List[int]) -> List[str]:
pas
- What is the actual output?
mypy test.py
test.py:8: error: Argument 1 of "test" is incompatible with supertype "A"; supertype defines the argument type as "Iterable[int]"
Found 1 error in 1 file (checked 1 source file)
- What is the output you expect?
mypy test.py
Success: no issues found in 1 source file
-
What are the versions of mypy and Python you are using?
- mypy: 0.740
- python: 2.7.13 and 3.7.6 (tested both)
-
Do you see the same issue after installing mypy from Git master?
Yes (on 989626a)
Metadata
Metadata
Assignees
Labels
No labels