potiuk commented on issue #33373: URL: https://github.com/apache/airflow/issues/33373#issuecomment-1676784684
I think - if you **really** have problem with calculating your time in JINJA - better approach would be to add an optional `delta` parameter in TimeSensor. TimeDeltaSensor is specifically to handle case where you want to pause something until some time passed since DagRun started. This is the purpose of this operator. It's purpose is not to wait till specific time. TimeSensor on the other hand IS designed to wait until some specific time. And so it happen that in order to use it currently you would need to set that time to be "now() + timedelta" if you want to wait for specific delta since the Sensor has been created. You can do it with JINJA even now if you wish, but in order to be slightly easier, maybe it makes sense to allow the target_time in TimeSync to be not only `time` but also `timedelta' and in case it is timedelta, calculate target_time as now+ timedelta. I think I would welcome such PR given it is nicely documented and explains the options. -- 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]
