fix(chat_manager.py): limit the length of the exception message to 120 characters
This commit is contained in:
parent
df178e10e2
commit
b16084d927
1 changed files with 1 additions and 1 deletions
|
|
@ -177,7 +177,7 @@ class ChatManager:
|
||||||
logger.exception(e)
|
logger.exception(e)
|
||||||
# send a message to the client
|
# send a message to the client
|
||||||
await self.active_connections[client_id].close(
|
await self.active_connections[client_id].close(
|
||||||
code=status.WS_1011_INTERNAL_ERROR, reason=str(e)
|
code=status.WS_1011_INTERNAL_ERROR, reason=str(e)[:120]
|
||||||
)
|
)
|
||||||
self.disconnect(client_id)
|
self.disconnect(client_id)
|
||||||
finally:
|
finally:
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue