Skip to content

Commit d458554

Browse files
Fix db downgrade check condition (apache#52982)
* fix rollback from airflow3 * use fab for test * amend * fix test * revert condition fix and add shortcut if revisions are same * updating revision to 2.10.3 in condition * remove fab from tests
1 parent 8d9bd1f commit d458554

File tree

1 file changed

+1
-1
lines changed
  • airflow-core/src/airflow/utils

1 file changed

+1
-1
lines changed

airflow-core/src/airflow/utils/db.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1055,7 +1055,7 @@ def downgrade(*, to_revision, from_revision=None, show_sql_only=False, session:
10551055
log.info("Attempting downgrade to revision %s", to_revision)
10561056
config = _get_alembic_config()
10571057
# Check if downgrade is less than 3.0.0 and requires that `ab_user` fab table is present
1058-
if _revision_greater(config, _REVISION_HEADS_MAP["3.0.0"], to_revision):
1058+
if _revision_greater(config, _REVISION_HEADS_MAP["2.10.3"], to_revision):
10591059
unitest_mode = conf.getboolean("core", "unit_test_mode")
10601060
if unitest_mode:
10611061
try:

0 commit comments

Comments
 (0)