apache / apache/airflow

Airflow Dashboard inconsistent for failed dags.

Open
#57,492 3 comments 0 reactions 0 assignees View on GitHub
area:UI kind:bug
Dominant language
Python
Stars
46.9k
Forks
17.8k
Avg merge
2d 10h
Merged PRs (30d)
483

Description

### Apache Airflow version

Other Airflow 2/3 version (please specify below)

### If "Other Airflow 2/3 version" selected, which one?

3.0.4

### What happened?

Airflow Stats for "Failed dags" is inconsistent with History. On Stats, I see "1 Failed dags" but on History, I see "O Failed".

Network request to get "Dag Stats"

```
URL: GET ui/dashboard/dag_stats

Response:

{
"active_dag_count": 12,
"failed_dag_count": 1,
"running_dag_count": 0,
"queued_dag_count": 0
}
```

And network request to get "History".

```
URL: GET ui/dashboard/historical_metrics_data?start_date=2025-10-28T14%3A36%3A26.330Z

Response:

{
"dag_run_types": {
"backfill": 0,
"scheduled": 10,
"manual": 0,
"asset_triggered": 0
},
"dag_run_states": {
"queued": 0,
"running": 0,
"success": 10,
"failed": 0
},
"task_instance_states": {
"no_status": 0,
"removed": 0,
"scheduled": 0,
"queued": 0,
"running": 0,
"success": 36,
"restarting": 0,
"failed": 0,
"up_for_retry": 0,
"up_for_reschedule": 0,
"upstream_failed": 0,
"skipped": 0,
"deferred": 0
}
}
```

Image

Do you know if this is a BUG or a misunderstanding of the UI?

Thanks

### What you think should happen instead?

"Stats" and "History" should show the same value.

### How to reproduce

1. Go the "Welcome" page
2. Check the difference between "Stats" and "History" sections.

### Operating System

Debian GNU/Linux 12 (bookworm)

### Versions of Apache Airflow Providers

```
airflow@airflow-dags$ pip freeze | grep apache-airflow-providers

apache-airflow-providers-amazon==9.15.0
apache-airflow-providers-cncf-kubernetes==10.6.2
apache-airflow-providers-common-compat==1.7.4
apache-airflow-providers-common-io==1.6.3
apache-airflow-providers-common-sql==1.28.1
apache-airflow-providers-fab==3.0.0
apache-airflow-providers-grpc==3.8.2
apache-airflow-providers-http==5.3.4
apache-airflow-providers-mysql==6.3.4
apache-airflow-providers-slack==9.3.0
apache-airflow-providers-smtp==2.3.1
apache-airflow-providers-standard==1.9.0
```

### Deployment

Official Apache Airflow Helm Chart

### Deployment details

We use helm, k8s and argo

### Anything else?

_No response_

### Are you willing to submit PR?

- [x] Yes I am willing to submit a PR!

### Code of Conduct

- [x] I agree to follow this project's [Code of Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md)

Contributor guide

Open the contributing guide

Research direction

Start on the Welcome page by comparing the Stats and History sections, then inspect the GET ui/dashboard/dag_stats and ui/dashboard/historical_metrics_data responses shown in the report. Trace how each section derives its failed count and verify the fix by reproducing the reported mismatch; done means both sections show the same value.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
api, frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
63/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.