Hacker News new | ask | show | jobs
by PinnBrain 4136 days ago
Yes, tangent, but please support the movements in several states to abolish daylight savings time. Having time move out from under us has long been a pain for programming robust systems. Perhaps the 5th or 6th generation of Apple watch will not need to do such an archaic adjustment.
3 comments

Daylight Savings Time has some ill effects, true, but if you think that making life easier for programmers is a point that should convince the general public, you're sorely out of touch. For one, it's not all that difficult in the scheme of things. For another, programmers dealing with dates in the past will always have to consider it. Lastly, the general perception is that programmers get paid quite well enough and can suck it up and deal with this minor annoyance.
Just wait till we travel to other planets' timezones. That's when programmers will really earn their paychecks.
Or when timezones depend on how fast you are traveling.
I have worked on a fairly large scale distributed system where we had to deal with DST. The week before the switch was always the craziest. Until... we switched the boxes and the database to UTC. Even if DST is abolished, leap second will be something to deal with. I have so many things I hate about DST - like switching all our cross timezone meetings but programming is not one of them - always set your machines and DB to UTC and do the conversion in your app.
You could even set your servers to TAI and adjust for leap seconds in your app, so that you don't have to worry about timestamps going backwards during leap seconds.
But then relativity messes even that up.
While we're at it, all roads should be straight.

Hint: If your system depends on local time, it isn't going to be robust.