Use IOError to catch more exceptions

This commit is contained in:
Joscha 2019-11-30 16:30:52 +00:00
parent 1b9860ba1e
commit 455d2af251

View file

@ -207,7 +207,7 @@ class Connection:
return True return True
except (websockets.InvalidHandshake, websockets.InvalidStatusCode, except (websockets.InvalidHandshake, websockets.InvalidStatusCode,
socket.gaierror, asyncio.TimeoutError): OSError, asyncio.TimeoutError):
logger.debug("Connection failed") logger.debug("Connection failed")
return False return False