Live data from Hacker News

'Japan's millennium bug' ahead of Akihito's abdication

theguardian.com

61–70 of 99 posts

Re: 'Japan's millennium bug' ahead of Akihito's abdication

#61
post #25

Earlier quoted context omitted.

Interestingly, sometimes the system is used for future dates. For instance, my drivers license expires in September of H.31, which I guess will never happen now.

Does this imply that the driver's license becomes invalid and must be replaced with one in the new date system? Real question

Or -- perhaps more intriguingly -- given that the date in question will never occur, is it valid until the end of time?

Philosophically it's a rather fun question, but practically they'll probably just honor it until the corresponding date of the new era.

Re: 'Japan's millennium bug' ahead of Akihito's abdication

#63
post #59
post #47

Earlier quoted context omitted.

UTC is good but not enough; it may still bite you in the behind. What's the time difference between these 2 timestamps: 2016-12-31 23:59:50 UTC (unix time 1483232390) 2017-01-01 00:00:10 UTC (unix time 1483232410) That's right: 21 seconds, due to the added leap second 23:59:60. So then your next option is to use TAI (international atomic time). Of course for most applications, this extra/missing leap second doesn't m…

Wait: are you saying that Unix time does not take into account the leap second?!

Correct. POSIX time is defined as number of seconds per (non-leapsecond) day times number of complete day since the epoch, plus the number of seconds in the current day.

POSIX timestamps get weird around leap seconds. Time stamps get repeated, subtraction returns incorrect results, and so on.

Re: 'Japan's millennium bug' ahead of Akihito's abdication

#64
post #55
post #41

Earlier quoted context omitted.

Beer and cider is sold in pubs in imperial pints (bigger than US pints), but wines and spirits are sold in milliliters. See https://www.gov.uk/weights-measures-and-packaging-the-law

don't some parts of Europe also use decilitres for beverage packaging? I've seen bottles that are like "75dl", and it took me a few minutes to clue in.

750 Liters would be a very large beverage! A typical keg of beer is only around 59 liters.

Re: 'Japan's millennium bug' ahead of Akihito's abdication

#65
post #44
post #41

Earlier quoted context omitted.

Beer and cider is sold in pubs in imperial pints (bigger than US pints), but wines and spirits are sold in milliliters. See https://www.gov.uk/weights-measures-and-packaging-the-law

Good point, I’d forgotten wine and beer were different. I wonder what further examples of mixed up units the UK has?

Miles per Imperial gallon.

Re: 'Japan's millennium bug' ahead of Akihito's abdication

#66
post #55

Earlier quoted context omitted.

don't some parts of Europe also use decilitres for beverage packaging? I've seen bottles that are like "75dl", and it took me a few minutes to clue in.

750 Liters would be a very large beverage! A typical keg of beer is only around 59 liters.

1dL = 0.1L

Re: 'Japan's millennium bug' ahead of Akihito's abdication

#67
post #59

Earlier quoted context omitted.

Wait: are you saying that Unix time does not take into account the leap second?!

Correct. POSIX time is defined as number of seconds per (non-leapsecond) day times number of complete day since the epoch, plus the number of seconds in the current day. POSIX timestamps get weird around leap seconds. Time stamps get repeated, subtraction returns incorrect results, and so on.

IIRC google and the like solve this using a special time routine in their kernels that literally just spread the second out across the day. It's close enough.. and legal will still accept it for auditing requirements.

Re: 'Japan's millennium bug' ahead of Akihito's abdication

#68
post #59

Earlier quoted context omitted.

Wait: are you saying that Unix time does not take into account the leap second?!

Correct. POSIX time is defined as number of seconds per (non-leapsecond) day times number of complete day since the epoch, plus the number of seconds in the current day. POSIX timestamps get weird around leap seconds. Time stamps get repeated, subtraction returns incorrect results, and so on.

If you use Java and the java.time API they added in the last release, you're covered for all of this.

https://docs.oracle.com/javase/8/docs/api/java/time/Instant....

In this segment, the Java Time-Scale is identical to UTC-SLS. This is identical to UTC on days that do not have a leap second. On days that do have a leap second, the leap second is spread equally over the last 1000 seconds of the day, maintaining the appearance of exactly 86400 seconds per day.

Java apps don't use UNIX time, they use something very similar called the Java timeline which is basically the same as UTC but leap seconds are smeared.

The java.time API is really incredibly thorough. It does of course have support for Japanese dates:

https://docs.oracle.com/javase/8/docs/api/java/time/chrono/J...

The type system and runtime checks also catch subtle errors like assuming "one day from now" and "in 24 hours from now" are the same thing.

Re: 'Japan's millennium bug' ahead of Akihito's abdication

#69
post #40

Earlier quoted context omitted.

Oh wow, it must be insane to be co-author to the emperor ! From the outside it's a weird juxtaposion of a traditional, old (from a European point of view) system of state and an everyday modern way of conducting scientific research. You'd just not expect this kind of contact, somehow.

> From the outside it's a weird juxtaposion of a traditional, old (from a European point of view) system of state and an everyday modern way of conducting scientific research. You'd just not expect this kind of contact, somehow. Well, what seems to be the most visible European monarchy outside of its own country (the British) seems to still largely adhere to the custom of the monarch (and, to a lesser extent, the clo…

Prince William is a professional coast guard helicopter pilot. He has done real work in the past, at least.

Re: 'Japan's millennium bug' ahead of Akihito's abdication

#70

Earlier quoted context omitted.

750 Liters would be a very large beverage! A typical keg of beer is only around 59 liters.

1dL = 0.1L

My bad, thought the d was for deca, not deci.

I'm in the US and although I spent some time in Canada I am for the most part not used to seeing the metric system used day to day. My metric system knowledge basically is what I remember from elementary and middle school.

Post reply on HN