Repository navigation
Conversation
fat-catTW
left a comment
There was a problem hiding this comment.
Thanks for standardizing the latest-run definition.
Could we add coverage for two DagRuns with the same run_after?
|
Thanks! A tie now goes to the higher id, with a test in each place that picks the latest run. The Dag page also ordered by |
|
Fork CI: green. CI for the latest commit passed in your fork. The pull request is ready for maintainer review. Pull requests from contributors run their CI in the contributor's own fork. GitHub Actions is free and has no minute limit on public forks, while the CI capacity of the Apache Software Foundation is shared by every ASF project and is finite. Fork CI tested this branch merged with Latest run: https://github.com/yuseok89/airflow/actions/runs/43782681524 How this works: CI in your fork. This comment was posted automatically by the fork CI monitor from templates drafted with an AI-assisted tool, so it may contain mistakes. An Apache Airflow maintainer, a real person, will review the pull request once its fork CI is green. Why the first pass is automated. |
The Dags list filters and sorting,
GET /api/v2/dagsand the dashboard Failed Dags count picked a Dag's latest run differently from the Dag cards and the Dag page, which userun_after. They now all pick it byrun_after, so a backfill over a past interval or a manual run without a logical date no longer makes them disagree.This uses the
(dag_id, run_after)index from #74481. On 5M runs with 10% of the Dags dormant, aGET /api/v2/dagsrequest filtered or sorted by the latest run went from 1.7 to 3.3 s to about 25 ms, and the dashboard stayed the same.Before / After
Two Dags, one whose manual run without a logical date failed after an earlier scheduled run succeeded, and one whose run for an older interval failed after a newer scheduled run succeeded.
Before. The Failed Dags card shows 0, while the list it links to shows both Dags.
Screen.Recording.2026-10-28.at.11.27.08.AM.mov
After. The card shows 1, and the list shows only the Dag whose latest run failed.
Screen.Recording.2026-10-28.at.11.24.52.AM.mov
closes: #74482
related: #57492
Was generative AI tooling used to co-author this PR?
{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.