Embracing Bugs and Learning from Fixing

Vithushan Jey
Geek Culture
Published in
3 min readApr 12, 2023

A reflection on my personal experience

Photo by DeepMind on Unsplash

Introduction

Recently, I was watching a video on the YouTube channel of Jack Herrington, where he shared one of the traits of a good software engineer — to get excited and indulge in solving bugs by digging deeply into them and learning about the surrounding aspects of the problem and solution. It made perfect sense to me.

When I started my software engineering career, I wasn’t the best engineer (and still am not), but I was enthusiastic and ready to do anything to find solutions to problems. At that time my solutions weren’t always the best, but they were enough to run the program by solving the problems.

Here I would like to share one of my personal experiences where I learned the importance of embracing bugs and learning from fixing them.

My First Commit

I still remember my first commit to a production-ready repository of an enterprise application during my internship. The task was to write an excel sheet reader using Java and Apache POI library. Like all beginners, I started by writing spaghetti code — lines that were hard to understand by others but to me, functions stretched over many lines and variables that weren’t meaningful. In layman’s terms, it was not a good start for an intern.

I wrote a single function with more than 100 lines of code to read the excel sheets and store the details from the sheet into a relational database. I never considered any of the standard coding practices during the development. I thought I did a fantastic job. But the code review was my judgment day. You would have easily guessed the feedback. My first reaction was, “But it’s working. Why can’t we merge it?”. Then after a discussion with my Senior Engineer, I understood that standard coding practices are equally important to code workability.

Understanding and accepting the presence of an issue gives us clarity and pushes us to work on ourselves to fix those issues. The next day, I rewrote the function, separating the logic, using meaningful variables, and writing an efficient program that not only works but is also easily readable and understandable by fellow engineers. I felt happy when my code was accepted and merged after a code review for the first time in my career.

Be bold, make mistakes, learn a lesson, and fix what doesn’t work
Quote from Seth Godin

Embrace, Learn & Fix

Even after completing two years, bugs still happen here and there, and I still debug and refactor my code. Experience doesn’t give any immunity to bugs. But it gave me a sense of resilience and persistence in solving it. Also, it taught me that fixing issues is often the most effective way to learn about something previously unknown to us.

Problems are part of our life, and the best thing that we can do is embrace, learn, and fix them rather than get angry or upset. Bugs, issues, mistakes, and failures are inevitable in our journey. We should see them as learning opportunities. We can develop our problem-solving skills by understanding the root cause of the issue, developing systematic troubleshooting methods, learning from past experiences, and collaborating with peers to get a new perspective on solving the issue.

Conclusion

Our career is filled with good and bad times. Sharing a bad one will eventually help many others in navigating the same situations in a better way.

In conclusion, embracing bugs and learning from mistakes is a crucial aspect of software engineering. Rather than seeing bugs as a negative thing, we should use them as an opportunity to learn, grow, and become better software engineers.

--

--

Vithushan Jey
Geek Culture

Software Engineer with 3+ years of experience in JavaScript, TypeScript, React, Next.js, React Native, and Node.js