Closed
Description
Happy to submit a PR to fix but I think this is wrong
from io import BytesIO, TextIOWrapper
from typing import Optional
encoding = None # type: Optional[str]
buf = BytesIO()
TextIOWrapper(buf, encoding=encoding)
mypy_test.py:6: error: Argument "encoding" to "TextIOWrapper" has incompatible type "Optional[str]"; expected "str"
Metadata
Metadata
Assignees
Labels
No labels