uranusjr commented on code in PR #33858:
URL: https://github.com/apache/airflow/pull/33858#discussion_r1308370758
##########
airflow/models/dagrun.py:
##########
@@ -307,7 +307,7 @@ def active_runs_of_dags(
else:
query = query.where(cls.state.in_((DagRunState.RUNNING,
DagRunState.QUEUED)))
query = query.group_by(cls.dag_id)
- return {dag_id: count for dag_id, count in session.execute(query)}
+ return dict(session.execute(query))
Review Comment:
```suggestion
return dict(iter(session.execute(query)))
```
I believe this is enought for Python to choose the correct dict constructor.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]