simple_server: asyncio TimeoutError has moved

We didn't notice this because the logging was broken.
This commit is contained in:
Nirbheek Chauhan 2020-05-25 18:39:16 +00:00 committed by Matthew Waters
parent 77ae10ab66
commit 0776def18c

View file

@ -68,7 +68,7 @@ class WebRTCSimpleServer(object):
while msg is None:
try:
msg = await asyncio.wait_for(ws.recv(), self.keepalive_timeout)
except (asyncio.exceptions.TimeoutError, concurrent.futures._base.TimeoutError):
except (asyncio.TimeoutError, concurrent.futures._base.TimeoutError):
print('Sending keepalive ping to {!r} in recv'.format(raddr))
await ws.ping()
return msg