Being Overly Dry

An interesting discussion came up in the office today about using the ruby gem inherited_resources. Many people I work with or have worked with love it, they love the fact it dries the controller up does all the stuff they continually have to type. I don’t.

As a developer I’ve always subscribed to a couple of theories and one of those is something that was drilled into me in Maths in high school; Show your working out. It’s all very well to have the answer, but if you don’t understand how you got there, you have failed.

This is the number one thing I hate that software developers do, they overly abstract/dry code up until it’s no longer easily readable. They sacrifice all their readability, for dry, abstracted code.

The inherited_resources gem is a prime example of this, your controllers are left looking empty; It completely reverses the expected convention of having to define those restful methods. So when Newbie Programmer A arrives at your controller, there’s a whole heap of things going on he just doesn’t know about or understand.

By all means write dry, abstracted code, but think twice before abstracting every last inch out. Just like a lot of things in the world, abstracting and drying up your code is great when used in moderation.

Published by


I'm a 23 year old Australian male, have been programming in java for 2 years now. I also play alot of World of Warcraft which means i have no time for anything anymore :)