Skip to content

Fix partition key display and input handling#69702

Open
Lee-W wants to merge 3 commits into
apache:mainfrom
astronomer:ui-partition-key-polish
Open

Fix partition key display and input handling#69702
Lee-W wants to merge 3 commits into
apache:mainfrom
astronomer:ui-partition-key-polish

Conversation

@Lee-W

@Lee-W Lee-W commented Jul 10, 2026

Copy link
Copy Markdown
Member

Why

The trigger/materialize forms and run views mishandled partition keys — non-partitioned Dag runs showed a dangling "Partition key:" label, an emptied key was sent to the API and rejected with a 400, and the field appeared even where partitioning doesn't apply.

What

  • Hide the partition key line/stat when partition_key is null (run header, asset event view)
  • Normalize an empty or cleared partition key (""/undefined) to null before hitting the trigger, materialize, and asset-event APIs — no more 400 on a blank field
  • Show the trigger form's partition key field only for partitioned Dags, with a helper hint
  • Swap the manual asset-event partition key from a JsonEditor to a plain text Input — it's a string, not JSON
  • Default the runs table's partition_key column to visible for a partitioned Dag's runs tab, hidden elsewhere
  • Unify the label — cron/runtime-partitioned runs now say "Partition key" instead of "Mapped Partition key"

non partitioned

image

partitioned

image

Was generative AI tooling used to co-author this PR?
  • Yes (please specify the tool below)

  • Read the Pull Request Guidelines for more information. Note: commit author/co-author name and email in commits become permanently public when merged.
  • For fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
  • When adding dependency, check compliance with the ASF 3rd Party License Policy.
  • For significant user-facing changes create newsfragment: {pr_number}.significant.rst, in airflow-core/newsfragments. You can add this file in a follow-up commit after the PR is created so you know the PR number.

Lee-W added 3 commits July 10, 2026 17:35
Non-partitioned Dag runs showed a dangling "Partition key:" label, an
empty partition key typed then cleared was sent to the trigger/materialize
APIs and rejected with 400, the trigger form exposed the field even for
non-partitioned Dags, the manual asset-event partition key used a
JsonEditor for a plain string, and the runs table hid the partition_key
column even when its filter was shown for a partitioned Dag. Also unify
the partition key label so cron/runtime-partitioned runs no longer say
"Mapped Partition key".
@Lee-W Lee-W changed the title UI: Fix partition key display and input handling Fix partition key display and input handling Jul 10, 2026
@boring-cyborg boring-cyborg Bot added area:translations area:UI Related to UI/UX. For Frontend Developers. translation:default labels Jul 10, 2026
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. translation:default

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant