Skip to content

[v3-4-test] UI: Scope partitioned Dag run asset list to readable assets (#75213) - #75817

Merged
bbovenzi merged 1 commit into
v3-4-testfrom
backport-a462d68-v3-4-test
Oct 27, 2026
Merged

bbovenzi merged 1 commit into
v3-4-testfrom
backport-a462d68-v3-4-test

Conversation

@github-actions

Copy link
Copy Markdown
Contributor
  • Scope asset expressions to the assets the caller may read

next_run_assets scopes the asset scheduling expression it serves to the
assets the caller may read (#72864), and the dependencies graph followed
(#73008). Four endpoints still served DagModel.asset_expression verbatim:
the public Dag details endpoint, the UI Dag list, and both partitioned Dag
run endpoints. A caller authorized on a Dag but not on its upstream assets
could read every name and uri out of them, and the public endpoint needs no
UI to reach. Asset names and uris commonly encode bucket, table or dataset
names, which is why the rest of the asset API already scopes them.

The sibling assets array of the pending partitioned Dag run response
carries the same names; scoping that is a separate change with its own UI
consumers.

  • UI: Scope partitioned Dag run asset list to readable assets

The pending partitioned Dag run detail response carries two asset-bearing
fields. asset_expression is scoped to the assets the caller may read; the
sibling assets array was not, so one payload could blank an asset inside the
boolean tree while spelling its name and uri out one key over. That defeated
the redaction on this route, and the route's own asset dependency only checks
whether the caller may read assets at all -- there is no asset id in its path
for it to authorize against.

The counts and partition keys of a blanked asset are kept. They describe the
Dag's own schedule, which a caller who reached this endpoint can already read,
and dropping them would leave a stuck run with no explanation at all.

This endpoint is served only to the UI: the public v2 spec regenerates
byte-identical, and no airflow-ctl model references the response.
(cherry picked from commit a462d68)

Co-authored-by: Henry Chen henrychen@apache.org

…ts (#75213)

* Scope asset expressions to the assets the caller may read

`next_run_assets` scopes the asset scheduling expression it serves to the
assets the caller may read (#72864), and the dependencies graph followed
(#73008). Four endpoints still served `DagModel.asset_expression` verbatim:
the public Dag details endpoint, the UI Dag list, and both partitioned Dag
run endpoints. A caller authorized on a Dag but not on its upstream assets
could read every name and uri out of them, and the public endpoint needs no
UI to reach. Asset names and uris commonly encode bucket, table or dataset
names, which is why the rest of the asset API already scopes them.

The sibling `assets` array of the pending partitioned Dag run response
carries the same names; scoping that is a separate change with its own UI
consumers.

* UI: Scope partitioned Dag run asset list to readable assets

The pending partitioned Dag run detail response carries two asset-bearing
fields. `asset_expression` is scoped to the assets the caller may read; the
sibling `assets` array was not, so one payload could blank an asset inside the
boolean tree while spelling its name and uri out one key over. That defeated
the redaction on this route, and the route's own asset dependency only checks
whether the caller may read assets at all -- there is no asset id in its path
for it to authorize against.

The counts and partition keys of a blanked asset are kept. They describe the
Dag's own schedule, which a caller who reached this endpoint can already read,
and dropping them would leave a stuck run with no explanation at all.

This endpoint is served only to the UI: the public v2 spec regenerates
byte-identical, and no airflow-ctl model references the response.
(cherry picked from commit a462d68)

Co-authored-by: Henry Chen <henrychen@apache.org>
@bbovenzi
bbovenzi marked this pull request as ready for review October 27, 2026 20:51
@bbovenzi
bbovenzi enabled auto-merge (squash) October 27, 2026 20:51
@bbovenzi
bbovenzi merged commit e55e92a into v3-4-test Oct 27, 2026
80 checks passed
@bbovenzi
bbovenzi deleted the backport-a462d68-v3-4-test branch October 27, 2026 21:50
@github-actions github-actions Bot added this to the Airflow 3.4.1 milestone Oct 27, 2026
@github-actions

Copy link
Copy Markdown
Contributor Author

Hi maintainer, this PR was merged without a milestone set.
We've automatically set the milestone to Airflow 3.4.1 based on: merged to version branch
If this milestone is not correct, please update it to the appropriate milestone.

This comment was generated by Milestone Tag Assistant.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants