@@ -29,7 +29,7 @@ async def lifespan(app: FastAPI):
consumer_task = asyncio.create_task(consume_messages())
yield
if producer:
await producer.stop()
consumer_task.cancel()
The note is not visible to the blocked user.