Fix Python 3.10 collections import
This commit is contained in:
parent
9a4ababd9a
commit
4cffbaa68d
|
@ -4,7 +4,6 @@
|
|||
"""Various utilities that are used throughout the package."""
|
||||
|
||||
import asyncio
|
||||
import collections
|
||||
import html
|
||||
import inspect
|
||||
import io
|
||||
|
@ -43,6 +42,11 @@ else:
|
|||
from async_generator import asynccontextmanager
|
||||
current_task = asyncio.Task.current_task
|
||||
|
||||
if sys.version_info >= (3, 10):
|
||||
import collections.abc as collections
|
||||
else:
|
||||
import collections
|
||||
|
||||
Size = Tuple[int, int]
|
||||
BytesOrPIL = Union[bytes, PILImage.Image]
|
||||
auto = autostr
|
||||
|
|
Loading…
Reference in New Issue
Block a user