Time zones are hard because people are hard
Greetings from Australia!1 It's the morning of September 5th for me and the night of September 4th in the US. In two weeks when I fly back, I will leave Sydney at 9 AM and arrive in Los Angeles at 6 AM, that same day.
Timezones are annoying enough for regular people, but us software engineers have to deal with the fallout. Then you add in the political aspects and, well, you can't always store all data in UTC.
So what makes time zones so bad?
Look a distraction
c2 wiki was the birthplace of the extreme programming movement. Lots of fun history there; you can see how cultural positions on things like patterns and lisp slowly changed over time. Maybe I should do a deep-dive newsletter on it sometime.
Anyway, it's got this great page on Why Is Payroll Hard:
I once thought payroll was simple too. It turns out that it is essentially complex, because of all the special deals and weird practices that have been set up over years of union negotiations and HR people with strange ideas.
- People in Dayton get paid differently from people anywhere else.
- There are five people whose union dues are different from anyone else. No, really.
- There are approximately 50 states and 300 communities' taxes to be dealt with, including reciprocity. (If you work in A and live in B, you can pay the lower of the two communities' taxes. But if you live in B and work in A ...).
- [etc]
Payroll systems are immensely complicated. I've never had to code for one, and I'm guessing few of you have had to, either. I'd further guess that few of us have had to work on train routing or tax laws. The complexity of most systems is only implemented by a few people.
But ah, timezones! We've all done timezones! Doesn't matter whether you're a web developer in Chicago or a gamedev in Jakarta, timezones matter to you. And unlike that payroll system, it's scope is the entire world. If Nepal decides they want a 5:45 offset then the timezone software gotta handle that.
All human systems are complex, timezones are just one that we all have to deal with.
And it's just one of them
Two other complex human systems all engineers have to deal with:
- Names. All the different standards and corner-cases of names spawned the falsehoods programmers believe meme.
- Languages. RTL scripts, final forms, Turkish i. UTF8 is a hard.
I think it's interesting that both of these are international problems. It comes from trying to make software that's robust across all human cultures. The specifics of Chinese naming schemes affects how a Chilean programmers handles naming, even if they (perhaps shortsightedly) assume they will never have any Chinese users. So it's more a mix of "all human domains are hard" and "humans are diverse, so international domains are extra hard".
-
Which is why this newsletter is so short. btw there will only be four newsletters this month due to travel ↩
If you're reading this on the web, you can subscribe here. Updates are once a week. My main website is here.
My new book, Logic for Programmers, is now in early access! Get it here.