TimeSensorAsync does not use DAG timezone to convert naive time input #33256
Labels
affected_version:2.6
Issues Reported for 2.6
area:core
area:core-operators
Operators, Sensors and hooks within Core Airflow
kind:bug
This is a clearly a bug
Apache Airflow version
2.6.3
What happened
TimeSensor and TimeSensorAsync convert timezones differently.
TimeSensor converts a naive time into an tz-aware time with
self.dag.timezone
. TimeSensorAsync does not, and erronously converts it to UTC instead.What you think should happen instead
TimeSensor and TimeSensorAsync should behave the same.
How to reproduce
Compare the logic of TimeSensor versus TimeSensorAsync, given a DAG with a UTC+2 (for example
Europe/Berlin
) timezone and the target_time input ofdatetime.time(9, 0)
.Operating System
Official container image, Debian GNU/Linux 11 (bullseye), Python 3.10.12
Versions of Apache Airflow Providers
No response
Deployment
Other
Deployment details
EKS + Kustomize stack with airflow-ui, airflow-scheduler, and airflow-triggerer.
Anything else
No response
Are you willing to submit PR?
Code of Conduct
The text was updated successfully, but these errors were encountered: