修复无法取消协程的问题
This commit is contained in:
parent
2f705b86ce
commit
0d63944da4
@ -407,7 +407,12 @@ class BLiveClient:
|
|||||||
if message.type == aiohttp.WSMsgType.BINARY:
|
if message.type == aiohttp.WSMsgType.BINARY:
|
||||||
try:
|
try:
|
||||||
await self._handle_message(message.data)
|
await self._handle_message(message.data)
|
||||||
except:
|
except BaseException as e:
|
||||||
|
if type(e) in (
|
||||||
|
asyncio.CancelledError, aiohttp.ClientConnectorError,
|
||||||
|
asyncio.TimeoutError, ssl_.SSLError
|
||||||
|
):
|
||||||
|
raise
|
||||||
logger.exception('room %d 处理消息时发生错误:', self.room_id)
|
logger.exception('room %d 处理消息时发生错误:', self.room_id)
|
||||||
else:
|
else:
|
||||||
logger.warning('room %d 未知的websocket消息:type=%s %s', self.room_id,
|
logger.warning('room %d 未知的websocket消息:type=%s %s', self.room_id,
|
||||||
|
Loading…
Reference in New Issue
Block a user