File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change 1
- from collections .abc import Callable , Mapping , Sequence
1
+ from collections .abc import Awaitable , Callable , Mapping , Sequence
2
2
from contextlib import AbstractAsyncContextManager , AbstractContextManager
3
3
from threading import Event as ThreadingEvent
4
4
from types import ModuleType
@@ -219,4 +219,10 @@ ClientDisconnectHandler: TypeAlias = Callable[[engineio.Client.reason], Any]
219
219
ClientDisconnectLegacyHandler : TypeAlias = Callable [[], Any ]
220
220
ClientConnectErrorHandler : TypeAlias = Callable [[Any ], Any ]
221
221
CatchAllHandler : TypeAlias = Callable [[str , str , Any ], Any ]
222
- EventHandler : TypeAlias = Callable [[str , Any ], DataType | tuple [DataType , ...] | None ]
222
+ SyncEventHandler : TypeAlias = Callable [
223
+ [str , Any ], DataType | tuple [DataType , ...] | None
224
+ ]
225
+ AsyncEventHandler : TypeAlias = Callable [
226
+ [str , Any ], Awaitable [DataType | tuple [DataType , ...] | None ]
227
+ ]
228
+ EventHandler : TypeAlias = SyncEventHandler | AsyncEventHandler
You can’t perform that action at this time.
0 commit comments