fix: set prepared threshold to none for migrations (#6912)
* Set prepared threshold to none for migrations * [autofix.ci] apply automated fixes * ruff * revert search --------- Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
This commit is contained in:
parent
faac4db133
commit
72a8573b2f
1 changed files with 7 additions and 1 deletions
|
|
@ -49,6 +49,7 @@ def run_migrations_offline() -> None:
|
|||
literal_binds=True,
|
||||
dialect_opts={"paramstyle": "named"},
|
||||
render_as_batch=True,
|
||||
prepare_threshold=None
|
||||
)
|
||||
|
||||
with context.begin_transaction():
|
||||
|
|
@ -71,7 +72,12 @@ def _sqlite_do_begin(conn):
|
|||
|
||||
|
||||
def _do_run_migrations(connection):
|
||||
context.configure(connection=connection, target_metadata=target_metadata, render_as_batch=True)
|
||||
context.configure(
|
||||
connection=connection,
|
||||
target_metadata=target_metadata,
|
||||
render_as_batch=True,
|
||||
prepare_threshold=None
|
||||
)
|
||||
|
||||
with context.begin_transaction():
|
||||
if connection.dialect.name == "postgresql":
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue