You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2019/04/08 18:40:06 UTC

[GitHub] [airflow] feng-tao commented on a change in pull request #5065: [AIRFLOW-4261] Minor refactoring on jobs.py

feng-tao commented on a change in pull request #5065: [AIRFLOW-4261] Minor refactoring on jobs.py
URL: https://github.com/apache/airflow/pull/5065#discussion_r273185923
 
 

 ##########
 File path: airflow/jobs.py
 ##########
 @@ -675,10 +674,11 @@ def manage_slas(self, dag, session=None):
             qry = (
                 session
                 .query(TI)
-                .filter(TI.state != State.SUCCESS)
-                .filter(TI.execution_date.in_(sla_dates))
-                .filter(TI.dag_id == dag.dag_id)
-                .all()
+                .filter(
+                    TI.state != State.SUCCESS,
+                    TI.execution_date.in_(sla_dates),
+                    TI.dag_id == dag.dag_id
+                ).all()
 
 Review comment:
   do we know the actual sql difference between these two approach?

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services