uranusjr commented on code in PR #51043:
URL: https://github.com/apache/airflow/pull/51043#discussion_r2106255620


##########
providers/standard/src/airflow/providers/standard/sensors/time.py:
##########
@@ -88,8 +88,12 @@ def __init__(
 
         # Create a "date-aware" timestamp that will be used as the 
"target_datetime". This is a requirement
         # of the DateTimeTrigger
+
+        # Get date considering dag.timezone
         aware_time = timezone.coerce_datetime(
-            datetime.datetime.combine(datetime.datetime.today(), target_time, 
self.dag.timezone)
+            datetime.datetime.combine(
+                datetime.datetime.now(self.dag.timezone), target_time, 
self.dag.timezone
+            )

Review Comment:
   ```suggestion
               datetime.datetime.now(self.dag.timezone)
   ```



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

Reply via email to