Would it be too much to have a global movement for uniform time standards? No half-hour timezones, no daylight savings, no leap seconds, just easily predictable time. Calendars are supposed to be convenient, and right now our ancient conventions make it difficult to understand each other (not just computers; think of travelers having to adjust to timezones, "do I need DST or not?"). At least, lets think of the electr…
You may be interested in the following articles: "So you want to abolish time zones" https://qntm.org/abolish >We already do have a global standard time zone, and everybody who cares already uses it: UTC. There are also more accurate time standards in use for more specialist purposes. "You advocate a ________ approach to calendar reform" https://qntm.org/calendar These links helped convince me that while time zones a…
Falsehoods programmers believe about time and time zones
71–80 of 83 posts
Re: Falsehoods programmers believe about time and time zones
#72Dealing with timezones and daylight savings time has consumed hundreds of hours of my development time. This seriously should be a standard service of the operating system, not the programming language library. Just look at all the code to deal with it in D (written by Jonathan Davis): https://github.com/dlang/phobos/blob/master/std/datetime.d
Operating systems kind of suck at it. Which is why for Elixir I made Tzdata ( https://github.com/lau/tzdata ) not rely on any timezone information from the operating systems. A feature I would like from operating systems is to tell me the true time during leap seconds. E.g. 23:59:59, 23:59:60, 00:00:00 Instead of repeating 23:59:59 or just pretending the leap second never happens.
Edit: Seems like we can specify CLOCK_TAI for clk_id on linux now.
Re: Falsehoods programmers believe about time and time zones
#73Earlier quoted context omitted.
I couldn't agree more - to boot, DST going away solves like half of the edge cases with one quick fix.
Except that removing DST won't, if you ever need to calculate a time/date for any time before its (future, hypothetical) removable. That could actually create more bugs.
Re: Falsehoods programmers believe about time and time zones
#74Earlier quoted context omitted.
That is one of my all-time favorite youtube videos... This one, and a similar one on unicode[1], are my goto exhibits when I need to illustrate to a non-technical family member how much background complexity is involved in software [1] https://www.youtube.com/watch?v=MijmeoH9LT4
I would think the time zone example would go over better than Unicode, because it's less esoteric. Almost everybody deals with time zones at some point; not everybody deals with Unicode.
(Yes, yes, amounts to the same thing. Except when it breaks.)
Re: Falsehoods programmers believe about time and time zones
#75Would it be too much to have a global movement for uniform time standards? No half-hour timezones, no daylight savings, no leap seconds, just easily predictable time. Calendars are supposed to be convenient, and right now our ancient conventions make it difficult to understand each other (not just computers; think of travelers having to adjust to timezones, "do I need DST or not?"). At least, lets think of the electr…
Swatch Internet Time is going to really take off one day.... https://en.wikipedia.org/wiki/Swatch_Internet_Time
Re: Falsehoods programmers believe about time and time zones
#76Earlier quoted context omitted.
You may be interested in the following articles: "So you want to abolish time zones" https://qntm.org/abolish >We already do have a global standard time zone, and everybody who cares already uses it: UTC. There are also more accurate time standards in use for more specialist purposes. "You advocate a ________ approach to calendar reform" https://qntm.org/calendar These links helped convince me that while time zones a…
I think timezones are useful. But the rest is not. We could just agree on a (non-solar) calendar that is predictable for the next, say 1000 years.
Re: Falsehoods programmers believe about time and time zones
#77Earlier quoted context omitted.
> It bothers me that a minute is not always 60 seconds. For leap seconds why did we choose 23:59:60 instead of 24:00:00? But how does this solve the problem? Sure, 23:59 is now 60 seconds long, but the minute 24:00 is only 1 second long.
It's about consistency. 23:59:60 is introducing a special case to the seconds field which you have to account for. 24:00:00 only adds a second to the day where it naturally should go. I don't redefine what a minute is, a minute is always 60 seconds. You are confusing two separate ideas, displaying a time and finding the difference between two times. Lexically you wouldn't say that minute is 1 second long, you would s…
Re: Falsehoods programmers believe about time and time zones
#78> If I have a timestamp for a future event, I can convert it to UTC, store it as UTC along with the time zone and be sure that I can reliably convert it back to the correct “wall time” in the future This actually looks like a subtle type safety and casting problem. Not all time specifications belong to the same type.
I guess they refer to jurisdictions changing their time zones or DST rules every so often. Note how they're only talking about the future, because that's where policy changes typically apply.
For future dates, you are often trying to represent "wall time", not a specific point in time, which is why storing as UTC is the wrong representation - it's something that maps to the information you want, but the mapping can change between storage and retrieval.
Re: Falsehoods programmers believe about time and time zones
#79Earlier quoted context omitted.
"(Sorry about that, but we can’t show files that are this big right now.)" 1.3MB and it's actually raw code. Amazing.
Daylight Savings Time should die in the fires of hell.