File tree Expand file tree Collapse file tree 4 files changed +17
-4
lines changed Expand file tree Collapse file tree 4 files changed +17
-4
lines changed Original file line number Diff line number Diff line change 1717)
1818from functools import update_wrapper
1919from collections import OrderedDict
20+ import sys
2021
21- from typing_extensions import Protocol , TypedDict
22+ if sys .version_info [:2 ] >= (3 , 8 ):
23+ from typing import Protocol , TypedDict
24+ else :
25+ from typing_extensions import Protocol , TypedDict
2226
2327from ._utility import public_module
2428
Original file line number Diff line number Diff line change 1010 Any ,
1111 overload ,
1212)
13- from typing_extensions import AsyncContextManager
13+ import sys
14+
15+ if sys .version_info [:2 ] >= (3 , 8 ):
16+ from typing import AsyncContextManager
17+ else :
18+ from typing_extensions import AsyncContextManager
1419
1520from ._core import AnyIterable , aiter
1621from .contextlib import nullcontext
Original file line number Diff line number Diff line change 88 Any ,
99 Awaitable ,
1010)
11- from typing_extensions import Protocol , AsyncContextManager , ContextManager
1211from functools import wraps
1312from collections import deque
1413from functools import partial
1514import sys
1615
16+ if sys .version_info [:2 ] >= (3 , 8 ):
17+ from typing import Protocol , AsyncContextManager , ContextManager
18+ else :
19+ from typing_extensions import Protocol , AsyncContextManager , ContextManager
20+
1721from ._core import awaitify
1822from ._utility import public_module , slot_get as _slot_get
1923
Original file line number Diff line number Diff line change @@ -16,7 +16,7 @@ classifiers = [
1616 " License :: OSI Approved :: MIT License" ,
1717 " Programming Language :: Python :: 3 :: Only" ,
1818]
19- requires = [" typing_extensions" ]
19+ requires = [" typing_extensions; python_version<'3.8' " ]
2020
2121[tool .flit .metadata .requires-extra ]
2222test = [
You can’t perform that action at this time.
0 commit comments