--- name: ? status: compiling version: 0.0.0 maintainer: Neo dependencies: [patience] ---
drafting spec…
the universe did not have a file for this yet. writing one now. (first visit only: future readers will see this page instantly.)
--- name: ? status: compiling version: 0.0.0 maintainer: Neo dependencies: [patience] ---
the universe did not have a file for this yet. writing one now. (first visit only: future readers will see this page instantly.)
--- name: Time Zones slug: time-zones type: distributed systems patch status: unstable version: 40.1.0 released: 1884-10-22 maintainer: IANA (reluctantly) dependencies: - solar-noon - political-will - the-british-empire (legacy, deprecated) - daylight-saving-time license: Public Domain (disputed by Arizona) tags: - time - coordination - global-infrastructure - known-footgun ---
A global agreement to disagree about what "now" means, encoded as integer offsets from an arbitrary meridian passing through a London suburb.
The Earth rotates at a fixed rate. Humans, however, do not. Somewhere in the gap between those two facts, time zones emerged as a compromise between astronomy and the railroad industry, which needed trains to stop colliding because two towns had different opinions about noon.
The mechanism is simple in theory:
In practice, the current count is approximately 38 distinct offsets, because several nations chose UTC+5:30, UTC+5:45, and UTC+9:30 as acts of what can only be described as soft nationalism.
ERR_AMBIGUOUS_HOUR Clocks fall back. The hour 1:30 AM occurs twice.
ERR_NONEXISTENT_TIME Clocks spring forward. 2:30 AM does not exist today.
ERR_DST_MISMATCH Two systems disagree on whether DST is currently active.
ERR_OFFSET_NOT_OFFSET "Pacific Time" resolves to UTC-8 or UTC-7 depending on the month.
ERR_SAMOA_LINE_CROSSED Samoa skipped an entire calendar day in 2011. Data loss.
ERR_POLITICAL_REASSIGNMENT Region moved to a new zone for economic alignment. History unrevised.
"I scheduled the meeting for 9 AM. I did not specify 9 AM where." -- every remote team, every week
| Dependency | Status | Notes |
|---|---|---|
| daylight saving time | unstable | Actively being removed in several jurisdictions, slowly |
| UTC | running | The one true anchor. Itself depends on atomic clocks |
| political borders | unstable | Change without warning, invalidate zone data |
| the IANA tz database | running | Updated 10-20 times per year. Someone is always watching |
Q: Should I store timestamps in local time? A: No.
Q: Should I store timestamps in UTC? A: Yes.
Q: Why does my calendar app show the wrong time after I land? A: Your device resolved the zone at scheduling time. ambiguity was always there. The flight revealed it.
Q: Can I just ignore time zones? A: You can. Previous practitioners of this approach include companies that lost millions in trades, hospitals that double-dosed patients, and one developer who shall not be named who scheduled a cron job to run 23 times in one day.