hussein-awala commented on code in PR #33718:
URL: https://github.com/apache/airflow/pull/33718#discussion_r1306155294
##########
airflow/sensors/time_delta.py:
##########
@@ -64,7 +64,11 @@ class TimeDeltaSensorAsync(TimeDeltaSensor):
def execute(self, context: Context):
target_dttm = context["data_interval_end"]
target_dttm += self.delta
- self.defer(trigger=DateTimeTrigger(moment=target_dttm),
method_name="execute_complete")
+ self.defer(
+ trigger=DateTimeTrigger(moment=target_dttm),
+ method_name="execute_complete",
+ timeout=self.timeout,
Review Comment:
From the other PR:
> it makes me a bit uncomfortable to remove the feature to be able to set a
specific deferral timeout on a given deferral. not that it's necessarily all
that useful, but it's there.
So for the sensors, this deferral timeout should be always self.timeout and
added explicitly.
Also if the sensor fails for some reason, we will reset this timeout. For
example a sensor with 5 retries and 1h as timeout, if it fails after 30min on
each retry because a token is expired, the sensor will run for 2h30min > 1h
--
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]