XD-DENG commented on a change in pull request #5065: [AIRFLOW-4261] Minor refactoring on jobs.py URL: https://github.com/apache/airflow/pull/5065#discussion_r273068593
########## File path: airflow/jobs.py ########## @@ -723,7 +723,7 @@ def manage_slas(self, dag, session=None): emails |= set(get_email_address_list(task.email)) elif isinstance(task.email, (list, tuple)): emails |= set(task.email) - if emails and len(slas): + if emails: Review comment: This line is in the if-check block of `if slas:` (https://github.com/apache/airflow/blob/fc3b45a61ac51441c3b9e4d99a20473cd3664056/airflow/jobs.py#L673). It's impossible for `len(slas)` to be zero here (correct me if I missed anything here) ---------------------------------------------------------------- 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: us...@infra.apache.org With regards, Apache Git Services