
Time Zones Aren’t Offsets – Offsets Aren’t Time Zones - ingve
https://spin.atomicobject.com/2016/07/06/time-zones-offsets/
======
beeforpork
I found it amusing to learn about the Australian time zones: Australia is
basically divided into three parts, which could be very nicely +8, +9 and +10,
except it is +8, +9:30 and +10. OK. Except that in the south, two of the three
zones are split and do DST, which the north does not do, so you get +8, +10:30
and +11 in summer in the south (but the north keeps +8, +9:30 and +10).

Now, that was my amusement for a couple of years.

Then I learned that there is Broken Hill, which follows a time zone different
from the surrounding area because of the train track history. And there is
Lord Howe Islands, which uses a +0:30 minute DST shift instead of an hour.

And then I learned that history also experimented with 20 minute and 15 minute
DST shifts, and that double DST (or Hochsommerzeit in Germany) was quite
common, too.

You can probably go on and on and on as you dig deeper, and at some point,
anyone's mind will blow, I guess.

~~~
gumby
Why is it amusing? Australian states can be quite large and this allows all of
South Australia to share a common time, even though they span two (arbitrary)
"time zones". India does the same.

Russia tried to do what China does (one TZ) but it is pretty hard -- people
like to be awake when the sun is up.

~~~
hx87
"I want to wake up when the sun is up" doesn't conflict with single time
zones, as any resident of western Xinjiang can attest, but since it requires
that people get up at numerically earlier or later times, it does conflict
with "I want to wake up at 5-9am."

~~~
vacri
It does conflict, if you have to do business with people in the other end of
the timezone.

------
zeta0134
Computerphile did an _excellent_ overview of time zones and all their
complexities in the context of programming:

[https://www.youtube.com/watch?v=-5wpm-
gesOY](https://www.youtube.com/watch?v=-5wpm-gesOY)

I was quite surprised by some of the stranger rules out there, especially the
regions that chose to skip a day for whatever reason. Timezones are complex!
Far, far more complex than simple offsets.

------
andrewfromx
I changed all my clocks awhile ago to UTC 24 hour. My life is 0 to 23 as it
should be. An hour is an array index between that range. UTC is the standard.
Standards are great. Like headphone jacks. Imagine (john lennon voice)
everyone living this way. Stop thinking your 23 must be night time and my 7
must be start of day. They are just numbers. It's 20 right now. What does 20
mean? Nothing, it's just a pointer.

~~~
itp
I used to be firmly in your camp, and then I read this:
[https://qntm.org/abolish](https://qntm.org/abolish)

For the tl;dr crowd, pulled from that article (although I highly recommend you
just read it):

Abolishing time zones brings many benefits, I hope. It also:

\- causes the question "What time is it there?" to be useless/unanswerable

\- necessitates significant changes to the way in which normal people talk
about time

\- convolutes timetables, where present

\- means "days" are no longer the same as "days"

\- complicates both secular and religious law

\- is a staggering inconvenience for a minimum of five billion people

\- makes it near-impossible to reason about time in other parts of the world

\- does not mean everybody gets up at the same time, goes to work at the same
time, or goes to bed at the same time

\- is not simpler.

As long as humans live in more than one part of the world, solar time is
always going to be subjective. Abolishing time zones only exacerbates this
problem.

~~~
jedrek
The true tl;dr is this: hours are meta-information. Just like 5am is very
early in every time zone, 11pm is late. We expect businesses to be open from
8-11 to 16-19, just like we expect everybody to be awake between 11-21.

Now, remove that bit of metadata and we need to figure out how to
encode/transmit it again. At the end of the day, we just recreate time zones,
with the added downside of removing a common language we have while traveling
- Visit SF from the UK and not only are you jetlagged, but you need to
remember that every time of the day you're used to needs to be shifted by 8
hours. - and just... talking to people in other time zones.

Right now, if you post a story on HN about needing to get up for work at
4:30am, everybody will understand: this person gets up for work really early!
Move to UTC and it means nothing.

~~~
maxerickson
We already have "before sunrise" and "middle of the night" and "after dark"
and sunrise and sunset and so on. Most of the time, there's little or no gain
from attaching a number instead of using one of those.

(I'm not arguing in favor of switching, just pointing out that we already have
the descriptions for times of day)

~~~
joshAg
None of those are as exact as a specific time. Each of those phrases could be
hours long. When you say before sunrise, did you mean 7:00 AM because it's the
middle of winter or did you mean 4:00 AM because it's the middle of summer? I
live at 37 degrees latitude, less than halfway to the north pole from the
equator. It gets dark before 5 in the winter and after 9 in the summer. That's
a 4 hours swing, and I'm not even at a very high latitude.

~~~
maxerickson
My point was that conversationally, "the middle of the night" gets the point
across that you got up early. It wouldn't even matter if the sun were up, it
would still get the point across fine.

Pedants that were concerned about the fuzziness of such words could hound the
speaker for UTC.

~~~
rayiner
It doesn't. To me, "middle of the night" means midnight to one am. If you
meant like 3 am to catch a red eye flight, then I've misunderstood you.

~~~
Nadya
Languages almost always find ways to fill in gaps of how to express something.
Often through the form of shared knowledge or idioms.

"I woke up a few hours before the roosters' crow to catch a flight."

It would be awkward to say that today, but potentially less so in some
alternate-dimension universal time zone world where it could be a common idiom
for "wee hours of the morning". Hours would still have meaning, people at
least have the thought that "roosters crow at sunrise". So you got up a few
hours before sunrise, whenever that time was.

------
joshstrange
Haha, I have this sign [0] hanging in my work area along with a number of
other TZ-related quick-reference documents. After getting burned badly by pre-
existing code that assumed America/Mexico_City was the same as America/Chicago
(As in both were "Central" and had offsets of -6/-5). While they have the same
offsets they change between DT/ST 2 weeks apart. I learned of all of this less
than 2 weeks out from the change...

[0]
[https://www.dropbox.com/s/kwiddhvbj24th0s/2016-07-06%2015.56...](https://www.dropbox.com/s/kwiddhvbj24th0s/2016-07-06%2015.56.05.jpg?dl=0)

------
niftich
It's so much more pleasant to deal with datetimes and timezones when you have
a good API that doesn't muddle and mix concepts for you. The Java 8 time API
[1] stands out, which was co-authored by Stephen Colebourne of Joda-Time fame
[2].

[1]
[https://docs.oracle.com/javase/8/docs/api/java/time/package-...](https://docs.oracle.com/javase/8/docs/api/java/time/package-
summary.html)

[2] [http://www.joda.org/joda-time/](http://www.joda.org/joda-time/)

------
gregmac
Related and previously discussed: Falsehoods programmers believe about time
and time zones [1]

[1]
[https://news.ycombinator.com/item?id=11515125](https://news.ycombinator.com/item?id=11515125)

------
adamnemecek
My mind was blown a while back when I learned that there are timezones with
offsets that are not whole hours. E.g. Kathmandu is +05:45.

~~~
Animats
The Saudi government was considering running the really big clock (46 meter
diameter) in Mecca [1] on local solar time. The goal was to run the entire
Islamic world on Mecca time.[2] But it didn't happen.

[1]
[https://en.wikipedia.org/wiki/Abraj_Al_Bait](https://en.wikipedia.org/wiki/Abraj_Al_Bait)
[2]
[http://www.telegraph.co.uk/news/worldnews/middleeast/saudiar...](http://www.telegraph.co.uk/news/worldnews/middleeast/saudiarabia/7937123/Giant-
Mecca-clock-seeks-to-call-time-on-Greenwich.html)

~~~
thaumasiotes
All of China (the size of the US) operates on Beijing (east coast) time.

------
JoblessWonder
As someone who recently had to implement time zone (offset) preferences in a
web app to satisfy a "Daily Requirements" feature...

I just wanted to say that I hate time zones with a passion.

~~~
Marazan
This is the correct feeling

------
devy
To me, one of biggest culprits of DST is also the reason why offsets and
timezones aren't in 1:1 relationships. The arbitrary mandates of time changes
from all levels of local/state/nation governments had made it a big mess in
figuring out local times. Time should be continuous in nature. But it's not
when you apply all these manmade rules.

Here is the table[1] of most but probably incomplete rules.

[1]:
[https://en.wikipedia.org/wiki/Daylight_saving_time_by_countr...](https://en.wikipedia.org/wiki/Daylight_saving_time_by_country#Daylight_Saving_Time_rules_as_of_2016)

~~~
jedrek
DST is an issue, as is the political selection of time zones. There's a great
map[1] that shows how arbitrary time zone shifts are.

Even in the EU, the eastern edge of Finland is over an hour east of the center
of CET, while western Spain is two hours west of it. That means that during
the spring and autumn solstice, even though we have 12 hours of day and 12
hours of night, the sun over western Spain sets three hours after eastern
Norway. For Norway it makes sense, most of its people live smack in CET, but
for Spain it's a purely political gesture.

[1] [http://blog.poormansmath.net/how-much-is-time-wrong-
around-t...](http://blog.poormansmath.net/how-much-is-time-wrong-around-the-
world/)

------
kevb
I had an unusual timezone related bug.

I was adding "Night mode" to Nova Launcher, allowing a dark theme to be
applied after sunset. To accurately calculate sunrise/sunset the location
permission is required, but that's the only thing Nova Launcher needs the
permission for, and only Android 6.0+ has runtime (optional) permissions so I
didn't want to force the permission on everybody and needed a fallback.

I knew that time zones aren't offsets but locations (ish) and for calculating
sunrise/sunset they should be close enough. Nova pulls the device's time zone
(something like America/Chicago ), maps it to a lat/long, and calculates the
sunrise/sunset. It just depends on how accurate the timezone data is.

Public beta went fine, but stable release we start getting a small, but
concerning, amount of emails from people saying that their icons won't load,
or disappear, after the update. We're asking for information trying to find a
pattern, but it's across different Android versions and devices. Finally we
notice all the carriers are Canadian. Then it gets more specific, it's
Winnipeg (turned out it was actually Manitoba, the province Winnipeg is in).
First thing I test is setting my device timezone to America/Winnipeg, but
everything works fine for me. We're getting some more device information from
the reporters, and their timezone isn't America/Winnipeg. but
America/Resolute. That must be close to Winnipeg right?
[https://goo.gl/maps/E5vj5nHfJgu](https://goo.gl/maps/E5vj5nHfJgu) Notice how
far north it is.
[https://www.timeanddate.com/astronomy/canada/resolute](https://www.timeanddate.com/astronomy/canada/resolute)
And the sunrise/sunset times, or lack thereof...

I actually anticipated this, and there was some code to just use hard coded
times for cities too far north to have a sane sunrise/sunset. However either
that code broke later, or it only worked with GPS coordinates, and I assumed
all the timezones were safe.

I don't know why carriers in Winnipeg report the timezone as Resolute, but the
fix came in two stages. 1) Properly handle locations that don't have sane
sunrise/sunset times. and 2) Treat America/Resolute as America/Winnipeg

------
__jal
The programming mistakes people make relating to time are legion. I feel like
time/date, floating point and crypto are areas where nearly everyone (not just
programmers) would hugely benefit by coders only using libraries written by
the very few who are actually competent to write them[1].

And anyone who thinks they are qualified to write time related code by virtue
of having coexisted with clocks and time _definitely_ should not be writing
time related code.

[1] Time handling is different than FP and crypto, in that most of the
complexity is human-created and policy driven rather than deep math, but for
whatever reason people really don't understand that time handling is very
complex - it seems to be widespread Dunning-Kruger. So they repeatedly make
bad mistakes with very strange-seeming trigger conditions that can't be
debugged on demand until someone realizes it is a time related bug.

------
imkevinxu
That linked story about Michigan's -5:32:11 offset is hilarious
[https://github.com/eggert/tz/blob/master/northamerica#L979](https://github.com/eggert/tz/blob/master/northamerica#L979)

------
fascinated
I, for one, have enjoyed seeing this piece of content marketing on top of HN,
and will be buying this company's products and services. Good to see something
other than the Macro up here.

------
1_2__3
Did the author just collect a bunch of random bits of information from
Wikipedia and attempt to construct a thesis around it, or is there a point to
this article that I'm missing?

~~~
sb8244
When you select your "timezone" in a web application, you usually get a list
of offsets instead. If you live in a town which falls in an offset but the
timezone isn't consistent, then your time will not be correct at certain parts
of the year.

It is important to understand the difference so you can build a time system
that works for everyone, not just the majority.

~~~
douche
I'm increasingly becoming convinced that there is no reasonable way to build a
time system that works everywhere. It's ridiculously complicated.

~~~
sb8244
I think I would agree with you. It's definitely tricky.

------
wang_li
Uh. Eastern, Mountain, Atlantic, etc. are actual official time zones.
America/Detroit does not appear to be such.

~~~
sb8244
Devney mentions that she is focusing only on IANA timezones. See a list here
[https://en.wikipedia.org/wiki/List_of_tz_database_time_zones](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones)

America/Detroit is a valid IANA timezone. Eastern is not.

Edit: Etzos has pointed out that US/Eastern is on the list. Thanks for
correction.

~~~
wang_li
Ah. I missed that while skimming through the page. I was primarily responding
to the statement made that "they are also called “time zones” in casual
conversation." They are time zones in the official sense of the word.

Speaking as if the Olson tz database is authoritative and official reminds me
of when some small country cancelled summer time with only a few days notice
and our OS vendors were not going to be putting out a patch in time. While
explaining the process of downloading the Olson tz database and updating
systems manually, a coworker asked who gave them (the country's government)
permission to cancel DST. It took longer than it should have for me to come up
with an explanation that sovereign countries don't need permission from the
Internet or OS vendors to change their laws and regulations. The computers
track the government actions, not the other way around.

~~~
kps

      > some small country cancelled summer time with only a few days notice
    

Egypt just did that.

\- In April, Egypt announced daylight time would start July 7.
[http://english.ahram.org.eg/NewsContent/1/0/204655/Egypt/0/D...](http://english.ahram.org.eg/NewsContent/1/0/204655/Egypt/0/Daylight-
savings-time-in-Egypt-postponed-to--July.aspx)

\- On June 30, Egypt decided daylight time would start July 5.
[http://english.ahram.org.eg/NewsContent/1/64/232199/Egypt/Po...](http://english.ahram.org.eg/NewsContent/1/64/232199/Egypt/Politics-/Daylight-
savings-time-to-start-on--July-Minister.aspx)

\- On July 4, Egypt decided not to have daylight time.
[http://english.ahram.org.eg/NewsContent/1/64/232478/Egypt/Po...](http://english.ahram.org.eg/NewsContent/1/64/232478/Egypt/Politics-/Egypts-
cabinet-abolishes-daylight-saving-time.aspx)

