You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by "rishi-kulkarni (via GitHub)" <gi...@apache.org> on 2023/08/02 17:51:30 UTC

[GitHub] [airflow] rishi-kulkarni commented on a diff in pull request #33045: FIX: set longer default `waiter_max_attempts` for deferred BatchJobOperator

rishi-kulkarni commented on code in PR #33045:
URL: https://github.com/apache/airflow/pull/33045#discussion_r1282241095


##########
airflow/providers/amazon/aws/operators/batch.py:
##########
@@ -223,7 +223,7 @@ def execute(self, context: Context):
                 timeout=self.execution_timeout,
                 trigger=BatchJobTrigger(
                     job_id=self.job_id,
-                    waiter_max_attempts=self.max_retries or 10,
+                    waiter_max_attempts=self.max_retries or 4200,

Review Comment:
   We could change it to be the default in the constructor, so it's more transparent to users? The reason I got tripped up in the linked issue is that it's implied that None is filled in with 4200, but it isn't when `deferrable=True`. 
   
   ```
           max_retries: int | None = None,
   ```



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