re: What's your most embarrassing coding story? VIEW POST

re: I'm intrigued

It was a long time ago (~1985) and software development was very different back then. We wrote the code on coding sheets using pencil, then we went to site, log on to the mainframe, and type our code into the system.

Testing was done using a process called side-by-side testing. That is, the customer would run their existing system along side the new system, and cross check the results.

Anyway, back to killing the cows.

I was making a change to the feed formulation program, used to calculate the ingredients that go into animal feed. Specifically I was updating the part of the program that calculates the amount of active ingredients (aka drugs) to add to the feed.

This was a fairly complicated process, working from a recipe a feed might require a certain amount of an active ingredient at a certain potency, but the actual amount added depends on the potency of the available batches of the active ingredient in stock, each having their own potency value.

Anyway, as you may have guessed on keying the update to the software into the system, an extra 0 had been added (actually I think, it may have been omitted not added, can't really remember) resulting in a 10 fold increase in the potency of the active ingredient added to the feed.

First I knew about my coding error was when I was called into the managing directors office at the software company I worked for and told that the feed company was being sued by the farmer who had lost a herd of cows because they had been fed this feed which too high a concentrate of some drug. In turn the feed company was looking to sue the software company.

Bit of an oops moment I can tell you.

Anyway, you may wonder why I mentioned testing above. Well, because we were updating a live system, the only real way to test the changes made was to run the process and compare it to the old system, which was part of the contract between the software company and the feed company. The feed company, to save time, just assumed that the new system would be correct, and didn't bother running the process through the old system to verify the results.

So the feed company in the end were liable.

I tell this story from time to time to highlight the importance of testing.

That's a good story! But those poor cows :-(

code of conduct - report abuse