DAG list: filter FAILED/RUNNING
Description
A few versions ago a very useful feature was introduced: allowing users to filter the home (DAG list) by RUNNING or FAILED DAGs. However, when you click on FAILED, all dags appear, even paused ones.
I believe the two sets of buttons should "work together". Therefore:
-
All+Failed: show all failed DAGs (paused and unpaused) -
Active+Failed: only show active failed DAGs - ....
Use case/motivation
We have many paused DAGs that finished with an error. It would be very useful to not see them so that it is easier to check actual errors.
Related issues
I've tried to find the PR that introduced this, but couldn't find it.
Thanks!
Are you willing to submit a PR?
- [ ] Yes I am willing to submit a PR!
Code of Conduct
- [X] I agree to follow this project's Code of Conduct
I've tried to find the PR that introduced this, but couldn't find it.
cc @PApostol as the original author of this feature https://github.com/apache/airflow/pull/30429 WDYT?
Thanks @eladkal for finding it! Following your concern (mixing Dag and DagRun properties) I believe that adding this should be "simple":
Instead of having:
arg_status_filter = request.args.get("status")
We should have
arg_status_filter = request.args.get("status") # all, active, paused
arg_lastrun_filter = request.args.get("lastrunstatus") # failed or running
Then, since we already have the queries (all_dags, active_dags, paused_dags, running_dags, failed_dags) it would be a matter of filtering the last two objects.
This is a good idea. At the moment, "Failed" tab doesn't distinguish between "All", "Active" or "Paused" (same applies for "Running" but that's probably less relevant). It would be nice for the tabs to work together.