Falsehoods programmers believe about time, etc (was Re: Leap Second planned for 2016)

Jay R. Ashworth jra at baylink.com
Sun Jul 10 17:34:32 UTC 2016


----- Original Message -----
> From: "Chris Adams" <cma at cmadams.net>

> Once upon a time, Patrick W. Gilmore <patrick at ianai.net> said:
>> But time _DOES_ flow. The seconds count
>> 	58, 59, 60, 00, 01, …
>> If you can’t keep up, that’s not UTC’s fault.

[ ... ]

> Leap second handling code is not well-tested and is an ultimate corner
> case.  There's been debate about abolishing leap seconds; with all the
> every-day bugs people have to deal with, few people set up a special
> test environment to handle something that may never happen again (until
> you get less than six months warning that it'll happen at least once
> more), and even then, tests tend to focus on what broke before, because
> it is really hard to test EVERYTHING.

If this particular issue is your beat -- or your avocation -- you really should
read both these blog postings, and all their comments; they are nearly
comprehensive:

  http://infiniteundo.com/post/25326999628/falsehoods-programmers-believe-about-time

and

  http://infiniteundo.com/post/25509354022/more-falsehoods-programmers-believe-about-time

They are also both funny as hell.



To myself be comprehensive, I should point out a companion piece about names:

  https://www.kalzumeus.com/2010/06/17/falsehoods-programmers-believe-about-names/

and there are similar lists for phone numbers, geography, civil addresses and gender,
linked from this thread:

  https://news.ycombinator.com/item?id=11321236

If you write any code that has to interface with the outside world, these are pieces
I think you should read at least annually.

Cheers,
-- jra


-- 
Jay R. Ashworth                  Baylink                       jra at baylink.com
Designer                     The Things I Think                       RFC 2100
Ashworth & Associates       http://www.bcp38.info          2000 Land Rover DII
St Petersburg FL USA      BCP38: Ask For It By Name!           +1 727 647 1274



More information about the NANOG mailing list