The GitHub Actions job "Tests (AMD)" on 
airflow.git/fix/ti-state-update-dag-run-deadlock has failed.
Run started by GitHub user avolant (triggered by avolant).

Head commit for run:
769cd71af2bc0bdd5ce8f2e152725b372b3d150c / avolant <[email protected]>
Fix deadlock in ti_update_state caused by FOR UPDATE locking dag_run

session.get(TI, id, with_for_update=True) emits a SELECT that joins
dag_run (via the lazy="joined" relationship) and applies FOR UPDATE to
both tables. Under concurrent task completions this serialises all
workers on the same dag_run row, producing deadlock cycles with the
scheduler's trigger-rule dependency checks.

Three other callsites in this file already use with_for_update={"of": TI}
for exactly this reason. Apply the same fix to the two remaining callsites
in _create_ti_state_update_query_and_update_state and its error-recovery
path.

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

With regards,
GitHub Actions via GitBox


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to