Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Import
Protocol
from typing_extensions (#5111)
Conditional imports must reference `sys.version_info` directly for type checkers to be able to narrow them. If a type checker cannot tell whether `PY_38` is true, it will combine the imports from both clauses in a `Union`. However, `typing.Protocol` and `typing_extensions.Protocol` are incompatible with each other - they do not inherit from the same class. This produces a type error which is reported to users of aiohttp depending on their type checking configuration.
- Loading branch information