-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Closed
Labels
Description
From python -m mypy.stubtest --custom-typeshed-dir . wsgiref
:
error: wsgiref.types._Readable.read is inconsistent, runtime argument "size" has a default value of type builtins.ellipsis, which is incompatible with stub argument type builtins.int
Stub: at line 28
def (self: wsgiref.types._Readable, builtins.int =) -> builtins.bytes
Runtime: at line 47 in file /Users/jelle/py/cpython/Lib/wsgiref/types.py
def (self, size: int = Ellipsis, /) -> bytes
The stub and implementation are exactly the same.
Probably stubtest should handle runtime Protocols more smartly.