Why you should delete code every sprint


Codebases and resource usage grow by accretion – we tack on new features, expand code to support new requirements and run scenario tests. Every now and then, we pay off some tech debt (if we’re lucky). 

What is more likely though is that we keep adding code and resources day in day out. Eventually, days stretch into weeks and weeks in turn, stretch into months.

Then, one day, there is a big ball of code that no one seems to understand what it does or how it works. Another symptom of this is having a huge cloud bill due to the proliferation of test resources. Worse still, no one seems to know how the situation degenerated so badly over the years.

JuNk!!

Clutter
Clutter

Do you remember the clothes you wore 10 years back? Where are they right now? What would happen if you never deleted gave out old clothes?

I love deleting code/artifacts so much because:

  • Deleted code can’t cause bugs (biggest win!)
  • You don’t have to debug deleted code – saves you from bloat and cognitive loads
  • Encourages simplicity and teaches people to keep the codebase clean and lean
  • Keeps running costs low

Perfection is achieved, not when there is nothing more to add, but when there is nothing left to take away.

Antoine de Saint-Exupery

Processing…
Awesome!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.