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 2020/01/10 18:25:28 UTC

[GitHub] [airflow] potiuk commented on a change in pull request #7133: [AIRFLOW-6535] first pass at exception to fail without retry

potiuk commented on a change in pull request #7133: [AIRFLOW-6535] first pass at exception to fail without retry
URL: https://github.com/apache/airflow/pull/7133#discussion_r365368228
 
 

 ##########
 File path: airflow/models/taskinstance.py
 ##########
 @@ -1120,10 +1125,33 @@ def handle_failure(self, error, test_mode=None, context=None, session=None):
             # only mark task instance as FAILED if the next task instance
             # try_number exceeds the max_tries.
             if self.is_eligible_to_retry():
-                self.state = State.UP_FOR_RETRY
-                self.log.info('Marking task as UP_FOR_RETRY')
-                if task.email_on_retry and task.email:
-                    self.email_alert(error)
+                if force_fail is not True:
 
 Review comment:
   ```suggestion
                   if not force_fail:
   ```
   
   or even better reverse the if and use `if force_fail:`

----------------------------------------------------------------
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