Repository navigation
Parse Dag files through the Task SDK importers - #73853
Merged
Merged
Conversation
dilnazanlid
marked this pull request as ready for review
September 28, 2026 16:05
dilnazanlid
requested review from
XD-DENG,
amoghrajesh,
ashb,
ephraimbuddy and
jedcunningham
as code owners
September 28, 2026 16:05
dilnazanlid
force-pushed
the
aip-85-parse
branch
from
September 28, 2026 16:21
40d1d1e to
1063c23
Compare
dilnazanlid
force-pushed
the
aip-85-parse
branch
2 times, most recently
from
September 29, 2026 07:47
1e38279 to
fc19b3b
Compare
Member
|
I think this makes sense. A few nits that I’ll touch later. Maybe we should mark this as experimental since #73457 is undecided. It looks like we can manage without breaking the interface, but I’d still add the experimental marker just in case for 3.4. |
Contributor
Author
|
Marked |
dilnazanlid
force-pushed
the
aip-85-parse
branch
2 times, most recently
from
September 30, 2026 15:00
340baf4 to
85c69d8
Compare
DagBag now discovers and imports Dag definitions through the bundle-scoped Task SDK importer registry, replacing the core importers package. Importers can be configured globally with [dag_processor] dag_importer_configs or per bundle via an importers key in dag_bundle_config_list. The source code and language reported by the importer are stored in DagCode, importer-namespaced warnings become Dag warnings, and the parsed definitions are sent to the manager so import errors are cleared per definition. DagFileParsingResult gains parsed_definitions and dag_source_codes.
…agImporter as experimental
dilnazanlid
force-pushed
the
aip-85-parse
branch
from
October 1, 2026 08:36
85c69d8 to
93d3c7e
Compare
uranusjr
approved these changes
Oct 1, 2026
pierrejeambrun
approved these changes
Oct 1, 2026
1 task done
This was referenced Oct 1, 2026
1 task done
1 task done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
sdk/importers: replace thedag_processing.importersbysdk/importersand move to Dag definitions.DagBag now discovers and imports Dag definitions through the bundle-scoped Task SDK
importer registry instead of the core
airflow.dag_processing.importerspackage, which is removed.
[dag_processor] dag_importer_configs, orper bundle through an
importerskey indag_bundle_config_list.fileloc,relative_filelocandbundle_nameon every imported Dag, soimporters that build Dags themselves (non-Python formats) are bound to their definition.
DagCode. Thesource is read once per file in the Dag processor instead of once per Dag in the manager.
yaml:deprecated_field) become Dag warnings and arecleared when no longer reported. Python warnings keep going to
captured_warnings.DagFileParsingResultgainsparsed_definitionsanddag_source_codes, with asupervisor schema version change.
Behaviour changes in internal APIs:
airflow.dag_processing.importersis removed. It had no configuration or docs, and itsimport_fileAPI differs from the SDK one.DagBag.file_last_changedvalues are freshness tokens (str) instead ofdatetime,and zip entries are keyed per member.
DagBag.has_loggedis removed. Files skipped by safe mode are now dropped duringdiscovery and logged at debug level.
The Dag processor manager still discovers only
.pyand zip files. Scheduled parsing ofother file types will be done in the follow-up PR that moves manager discovery to the registry.
Was generative AI tooling used to co-author this PR?
Generated-by: Antigravity following the guidelines