Skip to content

UI: Show a label instead of a broken link for hidden assets - #75178

Merged
bbovenzi merged 1 commit into
apache:mainfrom
henry3260:label-hidden-assets-in-asset-schedule
Oct 20, 2026
Merged

bbovenzi merged 1 commit into
apache:mainfrom
henry3260:label-hidden-assets-in-asset-schedule

Conversation

@henry3260

Copy link
Copy Markdown
Contributor

Why

next_run_assets scopes the asset scheduling expression it serves to the caller: an asset leaf
whose id is not readable keeps its place in the boolean tree, so the shape of the schedule stays
honest, but its uri, name and id are blanked and hidden is set (#72864).

The asset schedule popover never learned about that flag. AssetNode took every non-alias leaf down
the same path, so a redacted leaf rendered <RouterLink to={/assets/${null}}>{null}</RouterLink>:
a link with no visible text that navigates to /assets/null. The REST API documents hidden and the
generated TypeScript client exposes it, so the contract existed on both sides — only the UI side of it
was missing.

Deployments whose auth manager authorizes assets individually are the ones affected. The FAB auth
manager returns every asset id and the simple auth manager grants all or nothing above the lowest
role, so nothing is redacted there.

What

  • airflow-core/src/airflow/ui/src/components/AssetExpression/AssetNode.tsx — derive isHidden from
    the leaf's hidden field and give a hidden leaf its own branch: a lock icon and a muted
    Hidden asset label, with no link. Alias and readable-asset leaves render exactly as before.
  • airflow-core/src/airflow/ui/public/i18n/locales/en/common.json — add the expression.hiddenAsset
    key. Other locales fall back to English until translated.
  • airflow-core/src/airflow/ui/src/components/AssetExpression/AssetNode.test.tsx — new test that
    renders a readable leaf and a hidden leaf together, asserting the hidden one is labelled and
    contributes no link while the readable one keeps its /assets/1 link. It fails against main and
    passes with this change.

related: #72864


Was generative AI tooling used to co-author this PR?
  • Yes — Claude Code (Opus 5)

`next_run_assets` blanks the name and id of an asset leaf the caller may
not read and marks it `hidden`, keeping the shape of the schedule without
revealing which asset it waits on. The asset schedule popover did not know
about that flag, so a redacted leaf rendered as a link with no text
pointing at `/assets/null`.

Only deployments whose auth manager authorizes assets individually reach
this: FAB and the simple auth manager grant every asset id, so nothing is
redacted there.
@bbovenzi
bbovenzi merged commit 4ca5754 into apache:main Oct 20, 2026
78 checks passed
@github-actions

Copy link
Copy Markdown
Contributor

Backport successfully created: v3-4-test

Note: As of Merging PRs targeted for Airflow 3.X
the committer who merges the PR is responsible for backporting the PRs that are bug fixes (generally speaking) to the maintenance branches.

In matter of doubt please ask in #release-management Slack channel.

Status Branch Result
✅ v3-4-test PR Link

henry3260 added a commit that referenced this pull request Oct 21, 2026
…ts (#75178) (#75250)

`next_run_assets` blanks the name and id of an asset leaf the caller may
not read and marks it `hidden`, keeping the shape of the schedule without
revealing which asset it waits on. The asset schedule popover did not know
about that flag, so a redacted leaf rendered as a link with no text
pointing at `/assets/null`.

Only deployments whose auth manager authorizes assets individually reach
this: FAB and the simple auth manager grant every asset id, so nothing is
redacted there.
(cherry picked from commit 4ca5754)

Co-authored-by: Henry Chen <henrychen@apache.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:translations area:UI Related to UI/UX. For Frontend Developers. backport-to-v3-4-test Backport to v3-4-test translation:default

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants