September 16, 2016
I want to tell you a story of how you can make a mistake in software development by thinking small.
Often, developers have the tendency to become defensive and make excuses when they know they’ve implemented something in the wrong way.
How do these excuses sound?
A bunch of new features were requested by the client. They were like 5 new whole complex pages that we needed to implement.
Considering that now we had 5 more pages on the web application, some dependency management needed to be in place. So a team mate introduced an experimental dependency management (how..?) that at least kept us clear of the necessity of adding <script> tags in the HTML code. This was the beginning of the suffering.
Pages were implemented and released. The client was happy.
As soon as the next features were required for implementation, the issues with this whole approach started to show up. We had crashes from time to time, no consistency in the architecture, etc.
The next big mistake? Let’s solve these all by ourselves. So we’ve implemented a wrapper over this dependency management library in order to simplify things.
Soon, all the modules were to be using the new in-house developed THING. Why not picking up a library? See the excuses above.
New addition to the team: a more experienced colleague came and asked a lot of questions trying to understand why are we using the THING. He told me multiple concerns that I couldn’t accept at the moment because it affected my pride as a developer and as the creator of the THING.
However, I knew deep inside that he was right, but I needed some time to process this. After all, I agreed he has some points. What did I do? Instead of getting rid of it, I started adjusting the THING per his suggestions. Funny, right? :D
To be more clear, as much as I wished, I couldn’t just replace it with a library because it was too late, the code base was huge and one-time modifications like these could be “catastrophic” for the project.
I’ve worked hard to change the API signatures to match the ones from the library and finally I just switched the THING with the library.
Everyone was happy in the end because this really worked. It was, however, a much bigger price to pay comparing to what we would have been paid if we were to choose the library from the beginning.