Uh oh!
There was an error while loading. Please reload this page.
Fix execution failures with NULL dag_run.conf during upgrades - #56729
Conversation
Task execution and scheduler operations failed when processing dag runs with NULL conf values in the database. This occurred during Airflow 2.x to 3.x upgrades where existing running DAG runs had NULL conf, and when clearing dag runs that were migrated with NULL conf during offline migrations. The execution API DagRun datamodel required conf to be a dict, but the database schema allows NULL. This fix makes the conf field nullable to match the database schema, Core API datamodel, and Task SDK expectations. For backward compatibility, older API versions (pre-2025-10-10) will receive an empty dict instead of None when conf is NULL. Fixesapache#56707Fixesapache#56705
ephraimbuddy
commented
Oct 16, 2025
What do you think about my approach here: https://github.com/apache/airflow/pull/55884/files#diff-680cf6d70e96761db3869142642ba1df32e5c2c5c8d1b9ab65d0200dca4718daR229 |
kaxil
commented
Oct 16, 2025
Oh I hadn't seen that PR. The generated Task SDK client already accepts |
tirkarthi
commented
Oct 16, 2025
IMO, it will be good to have the db and models in sync. Similar report with our migration #50386 . |
kaxil
commented
Oct 16, 2025
Yeah, this PR makes it consistent. Could I get a review @tirkarthi |
(k8s failure fixed in #56733) |
Uh oh!
There was an error while loading. Please reload this page.
Backport failed to create: v3-1-test. View the failure log Run details
You can attempt to backport this manually by running: cherry_picker 0815019 v3-1-testThis should apply the commit to the v3-1-test branch and leave the commit in conflict state marking After you have resolved the conflicts, you can continue the backport process by running: cherry_picker --continue |
tirkarthi
commented
Oct 16, 2025
Thanks @kaxil |
Task execution and scheduler operations failed when processing dag runs with NULL conf values in the database. This occurred during Airflow 2.x to 3.x upgrades where existing running DAG runs had NULL conf, and when clearing dag runs that were migrated with NULL conf during offline migrations. The execution API DagRun datamodel required conf to be a dict, but the database schema allows NULL. This fix makes the conf field nullable to match the database schema, Core API datamodel, and Task SDK expectations. For backward compatibility, older API versions (pre-2025-10-10) will receive an empty dict instead of None when conf is NULL. Fixes#56707Fixes#56705 (cherry picked from commit 0815019)
…#56729) Task execution and scheduler operations failed when processing dag runs with NULL conf values in the database. This occurred during Airflow 2.x to 3.x upgrades where existing running DAG runs had NULL conf, and when clearing dag runs that were migrated with NULL conf during offline migrations. The execution API DagRun datamodel required conf to be a dict, but the database schema allows NULL. This fix makes the conf field nullable to match the database schema, Core API datamodel, and Task SDK expectations. For backward compatibility, older API versions (pre-2025-10-10) will receive an empty dict instead of None when conf is NULL. Fixesapache#56707Fixesapache#56705
Task execution and scheduler operations failed when processing dag runs with NULL conf values in the database. This occurred during Airflow 2.x to 3.x upgrades where existing running DAG runs had NULL conf, and when clearing dag runs that were migrated with NULL conf during offline migrations.
The execution API DagRun datamodel required conf to be a dict, but the database schema allows NULL. This fix makes the conf field nullable to match the database schema, Core API datamodel, and Task SDK expectations.
For backward compatibility, older API versions (pre-2025-10-10) will receive an empty dict instead of None when conf is NULL.
Fixes#56707
Fixes#56705
^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named
{pr_number}.significant.rstor{issue_number}.significant.rst, in airflow-core/newsfragments.