buggy culture

I am really surprised. The release is broken. How could this happen at this point and no one noticed it? Who is responsible for this feature?

I really think we should have a meeting to raise awareness about criticality.

How is this not tested?

Sounds familiar?

Software is a living organism that evolves over time and different people contribute to it, leave their marks. When you make a contribution, there are two states that interact with each other. The state you have in your mind that represents how you think the software works and the state that represents how it actually works. The bigger the difference between those states, the more likely that your contribution will cause a bug. This is why we see more bugs in big codebases and people want to make the code as simple as possible to understand so that the difference remains slim. However, it’s impossible for neither of those states to stay the same.

When you see a bug you need to think through all this before blaming it onto somebody or look for signs in the git history. In most of the cases, your software got too complex and interconnected that people cannot keep the difference low. Even if it’s a specific line or an obvious if statement, it’s caused by that difference; that if condition caused a bug only because the existing state led to that if condition to be false/true. This is why it’s pointless to blame individuals or look for someone to punish. Let me repeat; it’s not mercy to not blame people it is simply irrational.

In fact, the moment people see that the last person touched the line is called out, they will lose confidence in doing anything impactful before making sure everyone knows it, which leads to increased need for communication and sync between people. Basically, no one is doing anything before getting a sign-off. However, this is just being naive. You’d trick yourself that letting everyone know about every detail will save you, but, in such business culture, it won’t. So, you’re just losing time and energy.

Once the bug report comes in, look for who is the best one to solve the bug. Surely the person who introduced the specific line that supposedly caused the bug could be the most familiar with that flow of the code but that’s only the reason they are called; they are more familiar with that part of the software’s state. There are many cases where another person actually knows those parts better and would fix it faster and you should directly contact that person.

The moment a code is reviewed, approved and merged; it’s not yours anymore. If a bug occurs, it belongs to everyone who contributed to the software.

Still not convinced? Think of it this way. Do you pay the developer extra who wrote “Buy Now” button every time a sale happens to congratulate how the code piece he wrote brings in sales? No, because you know every sale is enabled by all part of the web site collectively. The same goes for bugs, too; they are caused by the whole codebase being that way, not by that one if statement.

Notes

Thanks to Erkan Erol for reading the drafts.

Follow @muvaffakonus on Twitter.