From 8a37a9570ba241427e58e7339d5c0782c769f1ff Mon Sep 17 00:00:00 2001 From: Vineeth Voruganti <13438633+VVoruganti@users.noreply.github.com> Date: Mon, 27 Oct 2025 16:58:10 -0400 Subject: [PATCH] fix: Improve alembic migration reliability --- migrations/env.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/migrations/env.py b/migrations/env.py index 8ee74328..6787437e 100644 --- a/migrations/env.py +++ b/migrations/env.py @@ -94,7 +94,10 @@ def run_migrations_online() -> None: prefix="sqlalchemy.", echo=False, poolclass=pool.NullPool, - connect_args={"prepare_threshold": None}, + connect_args={ + "prepare_threshold": None, + "options": "-c statement_timeout=300000", # 5 minutes in milliseconds + }, ) with connectable.connect() as connection: