I recently encountered an anti-pattern in the software world that is fundamentally a human behavior anti-pattern.Â I haven’t come up with a cute name for it yet, but it boils down to confusing the goal of a particular activity with the tools used to achieve the goal.Â In other words, the tools start to take a higher priority than the goal, and the goal suffers.
It’s easy to think of examples, in and out of the software world:
- Consistency in programming style:Â Consistency is something to strive for in your programming style, as consistency tends to make code better organized and more readable.Â The fundamental goal is readable, well organized, efficient code.Â Consistency is a tool used achieve that goal.Â It’s actually a very good tool for that goal, to the point of being an indicator of how well the goal has been achieved.Â But it can be overdone, and it must be remembered that the goal is clean, efficient, readable code, and that trumps consistency.
- Unions:Â I am loath to criticize unions, as unions are a very important tool for democratization and social change.Â Fundamentally a union is nothing more than a tool that allows working people to negotiate on an equal footing with the power elites of capitalist societies.Â This is inherently a good idea, and even a bad union is better than no union.Â Unions suffer from an undeservedly bad reputation in America thanks to a massive propaganda campaign (the Wisconsin plan, I believe it’s called).Â Â Â The anti union plan involves propaganda attacks on the unions at a deep cultural level over the last hundred years, and a systematic corruption and coopting of the Unions themselves.Â This system of corruption only works when the unions (and typically this is union organizers, not the union members themselves) allow themselves to prioritize the Union over the union, i.e. the organization over the solidarity.
- Flag burning, the patriot act, extraordinary rendition, overzealous patriotism, etc:Â What is any of this besides valuing the symbol over what is being symbolized?Â Patriotism, having pride in a flag, these concepts only have value when the nation being idealized has a value worthy of being idealized and spread.Â What value does our flag have when we have to restrict our freedoms to prevent people from ‘desecrating’ it?
- Virtually any concept in software engineering:Â single responsibility, small functions & classes, design patterns…Â Like consistency, the real value of these concepts is they provide conceptual tools which allow us to create cleaner, conciser, more flexible, understandable, robust, and maintainable code.Â Â But every single one of these concepts can be pursued to the point where it produces worse code.
- Zen.Â Believe it or not, I’ve heard of a guy who zealously practices zen meditation, but every time he loses his cool about something (loses his zen), he gets so worked up over his failure that he becomes temperamental and intolerable for weeks.
So let us be careful to understand what the goals are, and what the means are.