diff --git a/app/main.py b/app/main.py index b02bce4..f8a1dc8 100644 --- a/app/main.py +++ b/app/main.py @@ -15,7 +15,10 @@ async def lifespan(app: FastAPI): ok, msg = check_db() if ok: logger.info("Database connection OK") - run_migrations() + try: + run_migrations() + except Exception: + logger.exception("Migration failed — app will start but DB schema may be out of date") else: logger.warning("Database unreachable: %s", msg) yield