Re:It's Time for a Change: Datetime.utcnow() Is Now Deprecated
by efdee on Sunday November 19, 2023 @11:36AM
(#38334276)
There's no time zones involved in that at all. Nobody is going to be checking the opening hours of a Home Depot in another timezone and expect to get the date in their local timezone.
[ Parent
| on HN ]
Re:It's Time for a Change: Datetime.utcnow() Is Now Deprecated
by blincoln on Sunday November 19, 2023 @12:26PM
(#38334992)
> Nobody is going to be checking the opening hours of a Home Depot in another timezone and expect to get the date in their local timezone.
You've never wanted to call a business in another timezone before making the trip out there?
Re:It's Time for a Change: Datetime.utcnow() Is Now Deprecated
by Wowfunhappy on Sunday November 19, 2023 @03:59PM
(#38337909)
...I can see this use case.
However, if I look up the opening time of a Home Depot in another time zone, I expect the result to be in that store's local time! I'll do the conversion myself. If I get my local time instead, I'll still perform the conversion, and get the wrong result.
You could just decide that any time listed anywhere on the internet should include a timezone... but that would be nuts.