Repository navigation
Show the filtered task count in the Dag Tasks tab heading - #75448
Merged
bbovenzi merged 1 commit intoOct 23, 2026
Merged
Conversation
The Tasks tab filters the task list client-side (operator, trigger rule,
retries, mapped, name search) but passed the API's total_entries to the
DataTable heading, so the heading kept reporting the unfiltered count
("12 Tasks") even when a search narrowed the list to a single task.
Pass the filtered list's length instead, as Configs.tsx already does for
its client-built list, and assert the count in the existing filter tests.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
nanheekim-ovo
requested review from
bbovenzi,
choo121600,
guan404ming,
pierrejeambrun,
ryanahamilton,
shubhamraj-git and
vatsrahul1001
as code owners
October 23, 2026 07:34
|
Congratulations on your first Pull Request and welcome to the Apache Airflow community! If you have any issues or are unsure about any anything please check our Contributors' Guide
|
bbovenzi
approved these changes
Oct 23, 2026
|
Awesome work, congrats on your first merged pull request! You are invited to check our Issue Tracker for additional contributions. |
Contributor
Backport successfully created: v3-4-testNote: As of Merging PRs targeted for Airflow 3.X In matter of doubt please ask in #release-management Slack channel.
|
vatsrahul1001
pushed a commit
that referenced
this pull request
Oct 24, 2026
…#75448) The Tasks tab filters the task list client-side (operator, trigger rule, retries, mapped, name search) but passed the API's total_entries to the DataTable heading, so the heading kept reporting the unfiltered count ("12 Tasks") even when a search narrowed the list to a single task. Pass the filtered list's length instead, as Configs.tsx already does for its client-built list, and assert the count in the existing filter tests. (cherry picked from commit 99bdeab) Co-authored-by: 김난희 <nanhee.kim@ishopcare.co.kr> Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
vatsrahul1001
pushed a commit
that referenced
this pull request
Oct 24, 2026
…#75448) (#75490) The Tasks tab filters the task list client-side (operator, trigger rule, retries, mapped, name search) but passed the API's total_entries to the DataTable heading, so the heading kept reporting the unfiltered count ("12 Tasks") even when a search narrowed the list to a single task. Pass the filtered list's length instead, as Configs.tsx already does for its client-built list, and assert the count in the existing filter tests. (cherry picked from commit 99bdeab) Co-authored-by: 김난희 <nanhee.kim@ishopcare.co.kr> Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
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.
Why
On the Dag page, the Tasks tab filters the task list client-side (operator, trigger rule, retries, mapped, and the name search box), but the row-count heading above the table was fed the API's
total_entries. The heading therefore never changed as filters narrowed the list: with 12 tasks in the Dag and a search that leaves a single row, it still read "12 Tasks"!The
totalline predates the filters (#44604); client-side filtering was added in #54484 without touching it, and the heading became default-on in #57680, which is when the mismatch became visible.How
This passes
filteredTasks.lengthas theDataTabletotalinstead, so the heading follows the rows the table shows. That matchesConfigs.tsxandVersionDiff.tsx, which already pass the length of a client-built list.GET /dags/{dag_id}/tasksonly acceptsorder_byand returns every task withtotal_entries = len(tasks), so nothing else on this page depended on the server total, and the Tasks tab has no offset pagination that could be affected.The existing filter tests now also assert the heading count after each filter and after a name search; they fail on
mainand pass with this change.Observed on Airflow 3.2.2; the same line is on
main.Local results
Before PR screenshots
After PR screenshots
Since this is my first time, there may be some shortcomings.
Please let me know if any parts need revision or if I should submit a PR to a different branch.
Thank you!
Was generative AI tooling used to co-author this PR?