by enz on 5/9/24, 8:40 AM with 141 comments
by billpg on 5/9/24, 2:08 PM
A. A day is divided into a fixed number of smaller units.
B. Each smaller time unit is of a fixed physical duration.
C. The day cycle corresponds to the cycle of the solar day on Earth.
TAI picks A and B, allowing the solar cycle to drift from the time.UTC picks B and C, adding leap seconds to keep track with Earth's solar day cycle.
UT1 picks A and C, redefining the "second" to the changing rate of earth's solar day cycle.
by justin_ on 5/9/24, 10:23 AM
Contrary to this, since at least 2008[0], the POSIX standard (which is just paper not necessarily how real systems worked at that time) has said that "every day shall be accounted for by exactly 86400 seconds." That means that in modern systems using NTP, your Unix timestamps will be off from the expected number of TAI seconds. And yes, it means that a Unix timestamp _can repeat_ on a leap second day.
There's really no perfect way of doing things though. Should Unix time - an integer - represent the number of physical seconds since some epoch moment, or a packed encoding of a "date time" that can be quickly mapped to a calendar day? "The answer is obvious" say both sides simultaneously :^)
EDIT: I know DJB is calling out POSIX's choices in this article, but it seems like his "definition" does diverge from what the count actually meant to a lot of people.
[0] Also: "The relationship between the actual time of day and the current value for seconds since the Epoch is unspecified." https://pubs.opengroup.org/onlinepubs/9699919799.2008edition...
by re on 5/9/24, 10:00 AM
Most people seem to prefer ignoring leap seconds, pretending they don't exist by "smearing" them across the surrounding day, or even getting rid of them entirely. https://news.ycombinator.com/item?id=33658541 https://news.ycombinator.com/item?id=32226414
by aragilar on 5/9/24, 9:53 AM
Sidenote, "Tai" in the title should be TAI.
by umanwizard on 5/9/24, 9:50 AM
It really doesn't matter if UTC drifts away from solar time by an hour every few thousand years.
by vbezhenar on 5/9/24, 3:19 PM
by leandrod on 5/9/24, 4:40 PM
by prmoustache on 5/9/24, 11:08 AM