You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jobs@airflow.apache.org by GitBox <gi...@apache.org> on 2026/04/09 20:22:44 UTC

[GH] (airflow/2604/MIG_rules): Workflow run "Tests" failed!

The GitHub Actions job "Tests" on airflow.git/2604/MIG_rules has failed.
Run started by GitHub user Dev-iL (triggered by Dev-iL).

Head commit for run:
931fbf06727bebc199f084e16374919e26f180cb / Dev-iL <65...@users.noreply.github.com>
Add static analysis tests for migration anti-patterns

Prevent migration bugs like #64876 (DML before disable_sqlite_fkeys
silently breaking SQLite PRAGMA) from reaching production by adding:

1. AST-based static analysis tests (test_migration_patterns.py) that
   detect three anti-patterns across all migration files:
   - MIG001: DML before disable_sqlite_fkeys (triggers autobegin)
   - MIG002: DDL before disable_sqlite_fkeys (triggers autobegin)
   - MIG003: DML without context.is_offline_mode() guard

2. Unit tests for migration utility functions (test_migration_utils.py)
   covering disable_sqlite_fkeys, mysql_drop_foreignkey_if_exists, and
   ignore_sqlite_value_error with real database backends.

3. Fixes confirmed SQLite PRAGMA bugs in migrations 0100 and 0106 by
   moving all operations inside the disable_sqlite_fkeys block.

4. Adds # noqa: MIG0XX suppression comments (with reasons) to 20 old
   migrations with acknowledged violations, and configures ruff to
   preserve them via external = ["MIG"].

Report URL: https://github.com/apache/airflow/actions/runs/24207317623

With regards,
GitHub Actions via GitBox


---------------------------------------------------------------------
To unsubscribe, e-mail: jobs-unsubscribe@airflow.apache.org
For additional commands, e-mail: jobs-help@airflow.apache.org