1 Commits
Author SHA1 Message Date
hh ba348a35b7 fix(api): lifespan param named _app without dishka 2026-10-15 14:06:17 +02:00
@@ -18,7 +18,7 @@ NO_CACHE_HEADERS = {"Cache-Control": "no-cache"}
{% endif %} {% endif %}
@asynccontextmanager @asynccontextmanager
async def lifespan(app_: FastAPI) -> AsyncGenerator[None]: async def lifespan({% if use_dishka %}app_{% else %}_app{% endif %}: FastAPI) -> AsyncGenerator[None]:
setup_logging() setup_logging()
{%- if database != 'none' %} {%- if database != 'none' %}
await init_db() await init_db()