@@ -91,10 +91,22 @@ def get(self):
9191 contextvars = None # type: ignore
9292
9393import typing
94- from typing import Union , Any , Callable , List , Type , Tuple , Awaitable , Dict , overload
94+ from typing import (
95+ Mapping ,
96+ Union ,
97+ Any ,
98+ Callable ,
99+ List ,
100+ Type ,
101+ Tuple ,
102+ Awaitable ,
103+ Dict ,
104+ Sequence ,
105+ overload ,
106+ )
95107
96108if typing .TYPE_CHECKING :
97- from typing import Sequence , Deque , Optional , Set , Iterable # noqa: F401
109+ from typing import Deque , Optional , Set , Iterable # noqa: F401
98110
99111_T = typing .TypeVar ("_T" )
100112
@@ -426,7 +438,7 @@ def __anext__(self) -> Future:
426438
427439
428440def multi (
429- children : Union [List [_Yieldable ], Dict [Any , _Yieldable ]],
441+ children : Union [Sequence [_Yieldable ], Mapping [Any , _Yieldable ]],
430442 quiet_exceptions : "Union[Type[Exception], Tuple[Type[Exception], ...]]" = (),
431443) -> "Union[Future[List], Future[Dict]]" :
432444 """Runs multiple asynchronous operations in parallel.
@@ -480,7 +492,7 @@ def multi(
480492
481493
482494def multi_future (
483- children : Union [List [_Yieldable ], Dict [Any , _Yieldable ]],
495+ children : Union [Sequence [_Yieldable ], Mapping [Any , _Yieldable ]],
484496 quiet_exceptions : "Union[Type[Exception], Tuple[Type[Exception], ...]]" = (),
485497) -> "Union[Future[List], Future[Dict]]" :
486498 """Wait for multiple asynchronous futures in parallel.
0 commit comments