sse sub resource

This commit is contained in:
2026-07-12 00:51:23 +05:30
parent 4a7a76e330
commit f1a7a556fd
5 changed files with 59 additions and 60 deletions

View File

@@ -31,16 +31,12 @@ from starlette.middleware.cors import CORSMiddleware
from openapi_first.app import OpenAPIFirstApp
import routes
from sse import start_worker, stop_worker
@asynccontextmanager
async def lifespan(app):
start_worker()
try:
yield
finally:
stop_worker()
pass
app = OpenAPIFirstApp(