LionelZhao28 commented on pull request #17502: URL: https://github.com/apache/airflow/pull/17502#issuecomment-895192603
> And also there is one serious caveat (and one that should be covered by the unit tests) as well for sure is the DST change. UTC is not only easy to implement but guarantees conflict avoidance. With local time, if you have hourly scheduled DAG, you have a guaranteed conflict once a year - you will get the same run id conflict (when you move clock backwards). So unless you make sure that timezone is included and reflected properly, you might have a problem. > > I think in this case, the time zone offset will be different when you use isoformat, but it definitely needs testing (and what I mean by that unit testing) - so that we can avoid regressions and you actually have shown that you thought and tested that case consciously. > > Also i think it would be great to have parameterized unit > test with a number of more or less probable and 'weird' timezones. There are certain timezones (with half or even quarter-hour shifts) so it would.be great to see those tested as well. I see, it makes sense that the run_id may be conflicting if the system timezone is changed. But actually, for our usage, we really need a local run_id to show to find the specific dag run. But I've got another solution that we can add another filed name `local_run_id`, it is transformed from UTC to local time only on the page, the `local time` is the same as the timezone that the user setting on the right top on the page. So we only need to change the js or transform view logic. Do you think it is much better? -- 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]
