fix(dispatcher): todo

This commit is contained in:
mpa 2020-09-13 23:24:35 +04:00
parent edbae91418
commit 6e65d8fe27
No known key found for this signature in database
GPG key ID: BCCFBFCCC9B754A8

View file

@ -27,10 +27,10 @@ log = logging.getLogger(__name__)
DEFAULT_RATE_LIMIT = .1
def _ensure_loop(x):
def _ensure_loop(x: "asyncio.AbstractEventLoop"):
assert isinstance(
x, asyncio.AbstractEventLoop
), f"Loop must the implementation of {asyncio.AbstractEventLoop!r}, " \
), f"Loop must be the implementation of {asyncio.AbstractEventLoop!r}, " \
f"not {type(x)!r}"