potiuk commented on a change in pull request #20000:
URL: https://github.com/apache/airflow/pull/20000#discussion_r763071994
##########
File path: airflow/models/dag.py
##########
@@ -403,11 +403,12 @@ def __init__(
# set timezone from start_date
tz = None
if start_date and start_date.tzinfo:
- tz = pendulum.instance(start_date).timezone
+ tz = pendulum.instance(start_date, tz=start_date.tzinfo or
settings.TIMEZONE).timezone
Review comment:
Fine for me. It's just an annoying feeling that some of those edge cases
might fix some "real errors" :) and just indication in the commit message that
it could improve things might be good for commit message in this case:
"Improve handling edge-cases in airlfow models by applying mypy
suggestions", maybe :)
--
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]