4 min read
Technical debt horror

A headache all of us had experienced

I will not pretend as I have worked at tons of codebases already. In my career till now, I had the opportunity to work with 3-4 large codebases and few small codebases.

When I was joining my first job or even preparing for one, every cohort I joined, every developer I talked to, every social media developer account I read : all of them was teaching me one thing, to write clean and maintainable code. Sounds great, doesn’t it? And guess what, I followed these principles and they helped me land a job.

(this is the peace before disaster………🕊️)

Once I joined and started working on production codebases, I experienced something what we humans call : HELL. In 9 out of 10 codebases, the code was not even close to maintainable. Let’s just forget “clean code practices”. I initially thought, it has to be a co-incidence with me, the codebases I am working are the only ones which are cursed. But then…I have started talking to developers from other team, other projects, other companies. And the story is same for them also.

Few of them called these codebases as BLACK MAGIC. On top of that, I have heard statements like:

  1. “We don’t know, how it works. We just do our stuff, force push it and it runs”
  2. “This project can break anytime, we are just continuing, because none of us want to be slowing factor in the timeline”
  3. “We know its bad, but we don’t know who designed it this way, so a re-write is time consuming and we need to deliver next week”
  4. “Yes! we have react components with 1600-1700 lines each, but our seniors don’t allow us to refactor, saying that it just works”

And finally, let me add my two cents in it. I know we have to deliver and most often than not, we have to deliver in a time bound manner. Also, I very much aware of the fact that, in a team we work with people from different level of expertise. But the foundation of a project needs to alaways to be intact. And this is more for senior engineers, because the seniors are the one who comes to public and create this learning resources/courses, where they teach the code quality. So, when you guys are in the acting seat and you didn’t or couldn’t follow it, then please don’t pretend while you make your courses and don’t say lines like : “Clean code is the first skill you need to develop, because we always follow in the industry”. We are not school students, so please give us the glimpse of reality. And dear companies/product builders, the quality of the code, the cleanliness, the maintainbility : all of that matters. And the mental health of a developer is direct proportional to these factors of a codebase.

In the morning, when we engineers join the work, these factors decide, how our evening is going to be once we leave the office. So, next time, when an engineer asks more time and the reason is to better architect the codebase or prepare the documentation, please give him/her that time. Thank you.