Thursday, June 28, 2012

A Term Every Programmer Should Know: Blue Baby

One of the most critical skills a programmer can have is the ability to create a blue baby.

I've been saying this for years, but I don't think my fellow engineers understand me. Let me try to explain.

In the 2004 film, Something the Lord Made, two colleagues are pioneering a crazy idea that the heart can operated on successfully. Much of the movie is devoted to them working to save the lives of "blue babies" which are babies who's skin is literally blue due to lack of oxygen in the blood.

Their biggest challenge and much of the movie is devoted to reproducing the problem. Dr. Alfred Blalock and Vivien Thomas spend 13 years together, working to create the blue baby syndrome as a reproducible symptom in dogs.

Thirteen years.

They understood the importance of creating a blue baby.

Without the ability to create the exact same symptoms in an environment they controlled, they never would have had a breakthrough. More babies would have died and it may have been years before someone else was daring enough to attempt open heart surgery.

Every day, our worlds are being shaped and defined by the software we use. Companies and families rely on software and when it's broken, really bad things can happen. When it comes to software development, these same ideas are true. If there's a problem, you have to be able to reproduce it in a consistent, controllable way.

If you're a software engineer, you should be serious about your ability to create a blue baby. How creative and thorough are you when it comes to diagnosing, understanding, and reproducing a software problem? That's where the real skill and experience lie. Once the problem can be consistently reproduced, a few print statements later will often reveal a solution.

I think this idea of a "blue baby" in software development is critical (and this movie portrays it so well). I'm hoping my fellow developers will start using this term along with me. If your colleagues give you a sideways look as you yell, "Eureka! We've got a blue baby!", go ahead and send them this post.

Blue Baby: A term in software development referring to a bug that can be reproduced at will in a controlled environment. 

Your work may not be as important as open-heart surgery, but hopefully it doesn't take you 13 years to reproduce an important bug. What you do matters so fixing it matters too.

As a developer, what do you think? Is this term worthy to enter the lore of tech-speak such as bikeshedding, dogfooding, or rubberducking? (Cal Evans has a great post about the Software Development DSL you might also enjoy)

If you think so, share it with your communities. I'd also love your thoughts on this idea in the comments.


Fred Alger said...

I much prefer "[finding] the smoking gun." More of a detective / noir term and getting hard bugs to actually happen is usually a lot of detective work — tests, hacks, hunches, scientific wild-ass guesses. And once it's there, BAM, mystery solved, we've got the evidence needed to throw this bug in jail.

Terms that have the connotation of neonatal illness and death are not ones I like to throw around. My wife is a midwife and a doula.

Luke Stokes said...

Oh, man... I hadn't thought about it from that perspective. When I watched the movie, I was viewing this as something that was forever solved. Is the blue baby syndrome something that still happens today? I just Googled a bit and came up with a couple articles, one saying the last known case in the UK was 1972, another saying there have been no known deaths in Europe or North America in the last 50 years.

The fact that the term is connected to something so emotional (and, as I saw it, something that has forever been solved) is what drew me to the idea. It's also why I enjoy the movie so much. They saved these baby's lives! That, to me, is super awesome! To get that awesome, they had to reproduce the problem in a controlled way.

From a doula/midwife perspective, I can understand how any reference to a baby disease would be offensive and distasteful, but I was looking at it more from a "this is how they solved something so terrible" perspective.

As for finding the smoking gun, I like it! It doesn't carry the same emotional connection though.. and when I think about the detective movies I've seen, they just don't grab me the same way this one does. Sure, we have to stop the bad guy before he murders someone else... but we're saving babies here!

Either way, thanks for the comment. If it's offensive, it probably won't be picked up by the masses (nor would I want it to). But, if it can be seen as a way to solve a once terrible problem, I think it can still work.

Just my opinion though. :)

Jon Wolski said...

Reminds me of

Luke Stokes said...

Nice! Thanks Wolski. I loved the it's easier "than debugging with an eye of newt and the dust of a frog's ear."

I need to read that (and many other books) on programming. Even though I have a CSE degree, I feel self-taught sometimes since I haven't read some classic programming books.

The language he uses here fits so well with the Blue Baby term:
"Stabilize the Error: If you can't make a defect occur reliably, it's almost impossible to diagnose. Making an intermittent defect occur predictably is one of the most challenging tasks in debugging." He also mentions "controlled conditions" later in the post.

Great read. One of the challenges for me is the "Set a maximum time for quick and dirty debugging." part. As a high D programmer, I often like to fire all guns at a problem and hope for a quick win. That often leads to ASSumptions and partial solutions. I try to balance that with overall productivity which... sometimes works, sometimes doesn't. Sometimes I'm making great progress, but going no where (or is that "now here"?)