Comment On 2012... Just Because

"Most people spend their New Year's Eve watching the ball drop and celebrating the New Year," writes Jason, "and actually, that's what I planned to do, too. Instead, I found myself debugging our licensing activation system." "Just as I was about to leave the office, I received a torrent of emails with the subject 'License Activation Failed'. One or two every now and then is expected, but dozens and dozens at four o'clock on New Year's Eve... not so good. It took me a moment to realize the significance of 4:00PM, but then it hit me: I'm on Pacific Time, which is UTC -8 hours. [expand full text]
« PrevPage 1 | Page 2Next »

Re: 2012... Just Because

2012-01-02 09:04 • by First (unregistered)
Frist

Happy new year!

Re: 2012... Just Because

2012-01-02 09:05 • by Null (unregistered)
First (of January)!

Re: 2012... Just Because

2012-01-02 09:07 • by PiisAWheeL
Code Bomb?

Null:
First (of January)!


And its the Second.

Re: 2012... Just Because

2012-01-02 09:11 • by Raizer (unregistered)
Did the mayans put this code?

Re: 2012... Just Because

2012-01-02 09:12 • by Petr (unregistered)
The "World will end anyway" preparations?

Re: 2012... Just Because

2012-01-02 09:12 • by Suomynona (unregistered)
Should be 2013, as we all know it wont happen, just to be sure that no one can renew the license after the apocalypse.

Re: 2012... Just Because

2012-01-02 09:13 • by iluxa (unregistered)
370914 in reply to 370911
I think someone was just too fond of the end of the world idea

Re: 2012... Just Because

2012-01-02 09:15 • by PiisAWheeL
370915 in reply to 370914
iluxa:
I think someone was just too fond of the end of the world idea


That doesn't excuse the fact that they missed by about 11 (and some change) months.

Re: 2012... Just Because

2012-01-02 09:18 • by Poster (unregistered)
You need that kind of statement to test the error case.
Of course you're supposed to remove it after testing the error case...

Re: 2012... Just Because

2012-01-02 09:26 • by Melnorme
It really does look like intentional sabotage.

Re: 2012... Just Because

2012-01-02 09:32 • by Pim
And of course, as we all know the world will end after December 31, 9999. After all, that's when the calender ends.

Re: 2012... Just Because

2012-01-02 09:37 • by GalacticCowboy
svn blame
to the rescue!

Re: 2012... Just Because

2012-01-02 09:37 • by d (unregistered)
You took out the anti end of the world code!!! WHAT HAVE YOU DONE!!?!

Re: 2012... Just Because

2012-01-02 09:40 • by The poop of DOOM
370923 in reply to 370921
GalacticCowboy:
svn blame
to the rescue!

Gotta love blame! It's the sole piece in source control that keeps a team together.

Re: 2012... Just Because

2012-01-02 09:42 • by m
370924 in reply to 370920
Pim:
And of course, as we all know the world will end after December 31, 9999. After all, that's when the calender ends.

No, the problem of ending calendars was solved in RFC2550 once and for all. There is no escape from the world anymore.

Re: 2012... Just Because

2012-01-02 10:00 • by Pim
370925 in reply to 370924
m:
No, the problem of ending calendars was solved in RFC2550 once and for all. There is no escape from the world anymore.

Haha, that RFC was written on April the first. I'm not falling for that one!
Anyway, you say there's no escaping the world, but I can try.

\w\o\r\l\d

There.

Re: 2012... Just Because

2012-01-02 10:02 • by notromda
370926 in reply to 370921
GalacticCowboy:
svn blame
to the rescue!


Sadness is when you run that and you can only blame yourself. It's a double edged sword. :D

Re: 2012... Just Because

2012-01-02 10:07 • by FRooP (unregistered)
Maybe the IF should have been left in and changed to 2127 ... and I thought a part of the Y2K work was to centralise century windows, certainly not have them coded in-line in various modules ...

Re: 2012... Just Because

2012-01-02 10:14 • by Caoilte (unregistered)
It's still stupid, but perhaps it was put in for testing.

Would be interesting to find out how old the code is. My money is on ten.

Re: 2012... Just Because

2012-01-02 10:22 • by Not Frist (unregistered)
We had a radar simulation that crashed when a swerling number other that 4 was entered with a message saying..."Major error, Bye.'. After some digging, we hit your situation. Go figure.

Re: 2012... Just Because

2012-01-02 10:23 • by Adrian Wood (unregistered)
I would suggest it was perhaps put in long ago when there as no way any client could possibly be claiming a valid licence as far ahead as 2012, meaning anything with that year has to be invalid... except then, why would the code not test for any years AFTER then as well?

Still a fail regardless, of course!

Re: 2012... Just Because

2012-01-02 10:37 • by simonbuchan (unregistered)
There is, (of course) a real 2012 overflow: the DOS date format, which is still the "blessed" timestamp format in Zip files. NTFS and Unix format timestamps are fairly widely supported as well (though as extensions), but I'm expecting some nasty bugs to get flushed out over the year in various hand-written zip creator/readers (and you *know* there is a bunch of those!)

Re: 2012... Just Because

2012-01-02 11:18 • by Gary Olson (unregistered)
370933 in reply to 370918
Melnorme:
It really does look like intentional sabotage.


Looks like employment preservation code.

Re: 2012... Just Because

2012-01-02 11:31 • by P (unregistered)
370934 in reply to 370923
The poop of DOOM:
GalacticCowboy:
svn blame
to the rescue!

Gotta love blame! It's the sole piece in source control that keeps a team together.


Doesn't
svn praise
do exactly the same thing as well? :)

Re: 2012... Just Because

2012-01-02 11:49 • by DaveK
370935 in reply to 370931
simonbuchan:
There is, (of course) a real 2012 overflow: the DOS date format, which is still the "blessed" timestamp format in Zip files.
It may be the blessed timestamp format, but it doesn't roll over until 2107, as it has 7 bits for year number from 1980.

Re: 2012... Just Because

2012-01-02 11:57 • by ekolis
370936 in reply to 370922
You took out the anti end of the world code!!! WHAT HAVE YOU DONE!!?!


Dawn of The Second Day

48 Hours Remain...

Re: 2012... Just Because

2012-01-02 12:29 • by DaveK
370937 in reply to 370936
ekolis:
You took out the anti end of the world code!!! WHAT HAVE YOU DONE!!?!


Dawn of The Second Day

48 Hours Remain...
Jack Bauer would have already finished the game by now!

Re: 2012... Just Because

2012-01-02 12:31 • by Zecc
370938 in reply to 370925
Pim:
m:
No, the problem of ending calendars was solved in RFC2550 once and for all. There is no escape from the world anymore.

Haha, that RFC was written on April the first. I'm not falling for that one!
Anyway, you say there's no escaping the world, but I can try.

\w\o\r\l\d

There.
\⊕ or perhaps 🌐

Re: 2012... Just Because

2012-01-02 12:33 • by foo (unregistered)
370939 in reply to 370915
PiisAWheeL:
iluxa:
I think someone was just too fond of the end of the world idea


That doesn't excuse the fact that they missed by about 11 (and some change) months.
People should spend the last 11 months of the world contemplating their lives instead of dealing with crappy software licenses.

Happy New Year

2012-01-02 12:37 • by TRTDWTF (unregistered)

int days_in_december[15] = { 2, 5, 6, 8, 9, 12, 14, 15, 16, 19, 20, 22, 27, 29, 30 };

Officially welcome to the-less-than-half-daily-wtf.com.

Re: 2012... Just Because

2012-01-02 13:50 • by BushIdo (unregistered)
370943 in reply to 370939
Is there really a more effective way to stare into the abyss of human existence than dealing with crappy software?

Re: Happy New Year

2012-01-02 13:55 • by some guy (unregistered)
370944 in reply to 370940
TRTDWTF:

int days_in_december[15] = { 2, 5, 6, 8, 9, 12, 14, 15, 16, 19, 20, 22, 27, 29, 30 };

Officially welcome to the-less-than-half-daily-wtf.com.


Let it go, man, the last thing you want around here is to get Alex thinking about a site rename again. Well, next to last thing.

Re: 2012... Just Because

2012-01-02 16:33 • by will (unregistered)
Do need for sabotage, there is an INVALIDDATE section and this was probably a test for that. Someone did not remove a debugging statement.

Re: 2012... Just Because

2012-01-02 16:44 • by Omnifarious
My guess is that this was someone's ham-fisted attempt to keep people from entering dates that were 'too far' in the future.

If you have good source control you could figure out when that line was added and if there's a decent change comment about it.

Addendum (2012-01-02 17:06):
Which means that 'the real WTF' here is the fact that apparently the person who fixed this problem wasn't able to figure out why the change was put in in the first place using source control.

Re: 2012... Just Because

2012-01-02 17:44 • by F (unregistered)
370948 in reply to 370947
Omnifarious:
My guess is that this was someone's ham-fisted attempt to keep people from entering dates that were 'too far' in the future.

If you have good source control you could figure out when that line was added and if there's a decent change comment about it.

Addendum (2012-01-02 17:06):
Which means that 'the real WTF' here is the fact that apparently the person who fixed this problem wasn't able to figure out why the change was put in in the first place using source control.


You can have the best source control system in the known universe, but someone stupid enough to insert a line like that and leave it in production will almost certainly have put a completely bogus (or unintelligible) explanatory comment.

Re: 2012... Just Because

2012-01-02 17:45 • by Max (unregistered)
By removing the statement you have awoken Ctulhu

Re: 2012... Just Because

2012-01-02 18:05 • by Quicksilver
throw new IllegalStateException("Date not possible due to Mayan Calendar Error");


Anyone would dare to create a Mayan Calendar class for Java? ;-)

Re: Happy New Year

2012-01-02 18:20 • by a 'oi rgb (unregistered)
370951 in reply to 370944
some guy:
TRTDWTF:

int days_in_december[15] = { 2, 5, 6, 8, 9, 12, 14, 15, 16, 19, 20, 22, 27, 29, 30 };

Officially welcome to the-less-than-half-daily-wtf.com.


Let it go, man, the last thing you want around here is to get Alex thinking about a site rename again. Well, next to last thing.
Because someone who runs a free site is not entitled to a holiday over Christmas/New Year?

Re: 2012... Just Because

2012-01-02 18:31 • by BentFranklin
The Mayans correctly predicted the end of the world in 2012, due to GOTO statements.

Re: 2012... Just Because

2012-01-02 18:36 • by Atle (unregistered)
TRWTF is not grep'ing for invalid and date in the same line.

Re: 2012... Just Because

2012-01-02 18:53 • by Zekses (unregistered)
Should've been 2013. There'd be no one to care :)

Re: 2012... Just Because

2012-01-02 19:10 • by steve goodhall (unregistered)
"Go to"!?

Re: 2012... Just Because

2012-01-02 20:10 • by herby
370958 in reply to 370953
BentFranklin:
The Mayans correctly predicted the end of the world in 2012, due to GOTO statements.


GO TO 2012
2012 CONTINUE

(I couldn't resist).

Re: 2012... Just Because

2012-01-02 20:21 • by Totara (unregistered)
That was planned by your workmates so you would miss the office NYE party. They probably injected this a week ago in your back cos they didn't wanna see you at the party.

Re: 2012... Just Because

2012-01-02 21:20 • by 8bit (unregistered)
370960 in reply to 370916
Seriously?

You need that kind of statement to test the error case.


Wouldn't a real invalid date be better? 1854 or something. Otherwise what are you testing?


Of course you're supposed to remove it after testing the error case...


Oh oh so the real wtf is you tested code that no longer exists, was wrong to begin with, without an automated unit test,and the whole process is totally unreproducible.



Re: 2012... Just Because

2012-01-02 21:50 • by Anketam
World wont end in 2012, everyone knows it will end in 2038.

Re: 2012... Just Because

2012-01-02 21:54 • by da Doctah
370964 in reply to 370907
It took me a moment to realize the significance of 4:00PM, but then it hit me: I'm on Pacific Time, which is UTC -8 hours.


I had one of those blinding-flash-of-light moments back in the 90s. Our stand-in transaction processing system suddenly threw out a whole mess of "invalid currency" errors one July. Nothing we hadn't seen before, but the quantity of them hit an all-time one-day spike. When I was finally able to get the dumps, it turned out they were all coming from the same third-party channel (a consolidator for traffic from airlines), and all the invalid currencies were Canadian dollars (at that time the stand-in system could only handle US dollars, and we limited the channels based on whether we expected them to use anything else).

Suddenly it hit me. The first of July. Canada Day. Canucks all over the world who would otherwise never charge anything on their credit cards were suddenly flying back home on the same day. On Air Canada. And charging the tickets in loonies.

Re: 2012... Just Because

2012-01-02 22:04 • by syockit
The good thing is, it forces the maintainer to recheck the whole codebase

Re: 2012... Just Because

2012-01-02 22:04 • by lolwtf
370966 in reply to 370960
8bit:
You need that kind of statement to test the error case.


Wouldn't a real invalid date be better? 1854 or something. Otherwise what are you testing?
Go ahead and set your system clock to the year 1854 and let me know how it turns out.

Re: 2012... Just Because

2012-01-02 22:10 • by Coyne
370967 in reply to 370927
FRooP:
Maybe the IF should have been left in and changed to 2127 ... and I thought a part of the Y2K work was to centralise century windows, certainly not have them coded in-line in various modules ...


Nah. This defers the problem too long. He should have put in 2013...job security, you know. If he still works there, he can fix it December 30th to avoid the New Year's disruption.

If he doesn't, well, someone else can put it off for another year, right?
« PrevPage 1 | Page 2Next »

Add Comment