The Next Great Thing in Rubber Duck Debugging

Joey Profile Pic
Joey P.

There's a line in the second Harry Potter film where a wizard named Mr. Weasley asks “Tell me, what exactly is the function of a rubber duck?”

It’s a good question. Some acceptable answers: rubber ducks are for singing to in the bath, floating down a river as part of a creative fundraiser raise money, or to entertain your dog.

Developers, however, have a completely different answer to Mr. Weasley's question.

That's because for many developers their rubber ducks are more than a fun little toy, they are an integral part of their development process.

Ok, that sounds nuts. How can an inanimate object help developers find fixes for difficult and complex problems?

After all, rubber ducks are just a bit of injection molded squishy plastic with some paint.

However, developers find them valuable because rubber ducks are incredibly good at two things: listening and not judging.

Developers take advantage of these skills by talking through complex problems with their deskside rubber duck companions.

Talking to a rubber duck lets you take your time, be honest with yourself, and examine the problem from all angles before seeking outside help. This is often better than having this same conversation with a coworker - as that can be awkward and panic-inducing.

How Rubber Duck Debugging works for developers:

1. Ask your rubber duck if it has time to chat.

It’s important at this stage to find a quiet space to have a conversation with your duck companion. You don’t want to disturb others and or feel like you’re being overheard. Complete honesty is important and more difficult when you’re feeling self-conscious.

2) Explain what your code is supposed to do, going through it line by line.

By explaining what it is supposed to do you can better understand where the issue might be. You can also talk in a more abstract way to your duck if you’re just trying to define the problem. Your duck won’t mind.

3) Find a brilliant solution to your problem.

At some point, you’ll hit a snag in the code and realize the error of your ways. This Eureka moment is amazing and you might end up giving your duck high-five.

This style of debugging has become so popular that a bit of a cult has formed around rubber duck debugging. You can now even chat with a duck virtually via Rubber Duck Debugging if you can’t get your hands on a physical one.

But here’s the thing...

As much as we love our little yellow companions, it takes ages to comb through code line by line. And it’s not like the ducks are bringing much to the table outside of active listening. No valuable data. No critical insights into your crash defect.

How about this: Instead of spending hours talking to a duck, BugSplat users utilize crash data to quickly identify problems in their code that are causing crashes.

BugSplat records every crash as it happens, giving you instant access to in-depth crash data like symbolic call stacks, function names and line numbers, and a user description of the crash event.

No rubber duck in the world can do that.

We’re a little sad to make the role of rubber ducks redundant, but we like to think they’re pretty happy with their retirement.

Latest Stories

Here’s what we've been up to recently.

Get 'The Splat' newsletter from BugSplat

Join our other subscribers for product updates, crash reporting and development best practices, tips on running a startup, and deep dives into video game history.