You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "boushphong (via GitHub)" <gi...@apache.org> on 2023/08/26 15:58:06 UTC

[GitHub] [airflow] boushphong commented on a diff in pull request #33778: Fix UI DAG counts including deleted DAGs

boushphong commented on code in PR #33778:
URL: https://github.com/apache/airflow/pull/33778#discussion_r1306477300


##########
airflow/www/views.py:
##########
@@ -835,7 +835,9 @@ def index(self):
 
             is_paused_count = dict(
                 session.execute(
-                    select(DagModel.is_paused, func.count(DagModel.dag_id)).group_by(DagModel.is_paused)
+                    all_dags.with_only_columns([DagModel.is_paused, func.count()])
+                    .where(DagModel.is_active)

Review Comment:
   You're right. I just removed the redundant where clause.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org