mirror of
https://github.com/fastapi-practices/fastapi-best-architecture.git
synced 2026-10-13 12:49:28 +00:00
* Add asynchronous socketio application server * fix uv lock * Update cors * fix socket app
14 lines
252 B
Python
14 lines
252 B
Python
#!/usr/bin/env python3
|
|
# -*- coding: utf-8 -*-
|
|
from backend.common.socketio.server import sio
|
|
|
|
|
|
async def task_notification(msg: str):
|
|
"""
|
|
任务通知
|
|
|
|
:param msg:
|
|
:return:
|
|
"""
|
|
await sio.emit('task_notification', {'msg': msg})
|