Skip to content

Remove callbacks from DAG default_args when serializating it#57397

Merged
kaxil merged 1 commit intoapache:mainfrom
astronomer:callback-default-args
Oct 28, 2025
Merged

Remove callbacks from DAG default_args when serializating it#57397
kaxil merged 1 commit intoapache:mainfrom
astronomer:callback-default-args

Conversation

@kaxil
Copy link
Copy Markdown
Member

@kaxil kaxil commented Oct 28, 2025

Callbacks in DAG default_args were still being serialized as full function code, significantly bloating serialized DAG size. This change converts callback functions to boolean, similar
to how task-level callbacks are handled.

Follow-up of #54569 and #55849


^ 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.rst or {issue_number}.significant.rst, in airflow-core/newsfragments.

Callbacks in DAG `default_args` were still being serialized as full function code,
significantly bloating serialized DAG size. This change converts callback
functions to boolean, similar
to how task-level callbacks are handled.
@kaxil kaxil added this to the Airflow 3.1.2 milestone Oct 28, 2025
@kaxil kaxil merged commit 3b72458 into apache:main Oct 28, 2025
63 checks passed
@kaxil kaxil deleted the callback-default-args branch October 28, 2025 11:23
kaxil added a commit that referenced this pull request Oct 31, 2025
@ephraimbuddy ephraimbuddy added the type:bug-fix Changelog: Bug Fixes label Nov 10, 2025
odaneau-astro pushed a commit to odaneau-astro/airflow that referenced this pull request Mar 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants