Minor addition to chatroom test
This commit is contained in:
parent
b875093c8a
commit
089d525def
|
@ -20,6 +20,10 @@ async def message_handler(q: aiosched.Queue):
|
||||||
logging.info(f"Got message {msg!r} with the following payload: {payload}")
|
logging.info(f"Got message {msg!r} with the following payload: {payload}")
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
logging.error(f"An exception occurred in the message handler -> {type(e).__name__}: {e}")
|
logging.error(f"An exception occurred in the message handler -> {type(e).__name__}: {e}")
|
||||||
|
except aiosched.errors.Cancelled:
|
||||||
|
logging.warning(f"Cancellation detected, message handler shutting down")
|
||||||
|
# Propagate the cancellation
|
||||||
|
raise
|
||||||
|
|
||||||
|
|
||||||
async def serve(bind_address: tuple):
|
async def serve(bind_address: tuple):
|
||||||
|
|
Reference in New Issue