It was the French writer and philosopher Voltaire who observed, “The perfect is the enemy of the good.”
(Actually, since Voltaire was French, what he really observed was, “Le mieux est l'ennemi du bien.” It's a line from a 1772 poem called “La Bégueule.” He apparently meant “the better” or “the best,” not “the perfect,” but the aphorism survives in English as “the perfect is the enemy of the good.” People quote the line all the time without thinking too hard, I imagine, about its literal meaning.)
In the software development world, we quote Voltaire when we warn of the dangers of analysis paralysis: the pernicious state of spending so much time and energy on preparations that we never actually begin coding. It arises, I think, from the fear of making a wrong move, which is a fine fear to have, in moderation.
The aphorism also applies to the malady of elegance creep or gold-plating. Blogger Rick Kotermanski says that's what you get when you blow deadlines by addressing implied or unwritten nonfunctional requirements. “I have frequently found cases where programmers have built exotic and academically intriguing solutions to problems that don't really exist,” Kotermanski writes, “usually under the guise of addressing an anticipated but never realized performance or extensibility problem.” To which I can say only, “Um...guilty as charged.”
A thoughtful fellow named Vesa Palmu has observed, as many have, that an unbridled quest for perfection can lead to endless costs and delays. He's summarized the problem with a little chart that shows the relationship between value and development cost, and identifies an optimal zone in which costs are incurred most efficiently:
Obviously, the solution to perfectionism is to stop working when the code is good enough. But that's devilishly hard to do – coding isn't a “good enough” profession, in my experience. Parmu says, “I'm not trying to say it's good to lower your standards, not care about the visuals, or to cut back on quality. I'm just saying that you should know what is really important and pay attention to what your definition of done is.”
(A good many discussions of the perils of perfection wind up citing the Pareto Principle, the so-called 80-20 rule. The rule suggests that achieving the last 20 percent of perfection consumes 80 percent of your overall effort and budget. This insight sounds as if it ought to be true, and is constantly cited as if it were established fact, but to my knowledge it has never been tested in software development.)
The Buddhist notion of dukkha is helpful in any analysis of perfection. Buddhists accept as a core belief the idea that because the world is constantly changing, it cannot be in a state of perfection. As I understand it, dukkha is both the essential imperfection of life and the soul's inevitable dissatisfaction with the state of the universe.
I think the Japanese Zen concept of wabi-sabi, which is built upon a Buddhist foundation that includes dukkha, is likewise worth exploring. Wabi-sabi is an aesthetic principle. Wikipedia (which I am not above quoting when I am on deadline) says wabi-sabi ideals include “asymmetry, asperity, simplicity, economy, modesty, intimacy, and appreciation of the ingenuous integrity of natural objects and processes.” The site quotes Richard R. Powell, author of a 2004 book on wabi-sabi, who says the aesthetic acknowledges three simple realities: “nothing lasts, nothing is finished, and nothing is perfect.” It seems the Zen masters anticipated the Agile movement by several centuries.
The tendency toward perfectionism is natural in human beings and, I think, pretty much universal in programmers. Compilers reinforce our natural tendency to pay attention to the tiniest of details.
Ward Cunningham coined the term “technical debt” to refer to imperfections in source code. Speaking at OOPSLA in 1992, Cunningham said: “Shipping first-time code is like going into debt. A little debt speeds development so long as it is paid back promptly with a rewrite...Every minute spent on not-quite-right code counts as interest on that debt.”
Others have expanded on Cunningham's acute observation. Many note that just as businesses justifiably and deliberately take on debt to meet major goals, so a development team might reasonably incur technical debt in the service of a sufficiently high priority. This trade-off is implicit in Agile development.
At this point, I should be offering an assessment to help you identify whether you have succumbed to perfectionism on the job, plus a few tips on overcoming the malady. That's what the architecture of the magazine article requires. (Despite making hundreds of blog posts over the years, I don't understand the structure of the blog post, and I keep writing magazine articles. TL;DR, as they say in the online communities.)
But after hours of online research, I have no advice to offer. Articles that promise to help readers overcome perfectionism are packed with touchy-feely nonsense. Tech sites advise developers to weigh the costs of shipping a few bugs versus the cost of fixing them – advice that is simultaneously impossible to follow in the real world, wrong-headed, and almost certain to transform the developer's satisfying career into an unrewarding hell on earth.
Even the fabulously smart Joel Spolsky, whose Joel on Software I crib from when the rest of the Internet lets me down, backed down when he addressed this topic. After building a rigorous demonstration of why it makes economic sense to let certain imperfections remain in a code base, he closed with these weasel words: “With all that said, I'm optimistic at heart, and I believe that there is a lot of hidden value to producing very high quality products...So I tend to err on the side of quality (indeed, we fixed every known bug in FogBUGZ, not just the big bang ones) and take pride in that...”
Given an overwhelming absence of useful advice on this subject, I'll hazard one original thought. I think perfectionism is natural, inevitable, and desirable in software developers. Coders should always include perfectionism as part of their motivation for learning, exploring alternatives, tinkering, debugging, and rethinking. The tendency to pursue perfection makes developers more valuable.
Projects go astray, however, when that tendency is given free rein. For that reason, managers – not developers – must cultivate a big-picture perspective so they can call a halt to endless development cycles that no longer justify their cost.
I realize I am merely shifting the burden of combating perfectionism to someone else, not solving it. But the bottom line is that this is precisely the soft of task management was invented to perform. We count on managers to monitor the big picture and ship the code when it's time. Evaluating the trade-off between costs and benefits is what managers are good for.
Web recommendation: Larry O'Brien and I continue to poke holes in the persistent notion that our industry has, and needs, superprogrammers. My experience is that many excellent coders suffer from personality traits – elitism, dismissal of others' talents, endless self-congratulatory back-patting – that would make me avoid working with them even if they were as good as they thought they were. Development-industry traditions make the situation worse, perpetuating the myths and lionizing the arrogant. One harmful bit of intellectual scaffolding that supports this harmful notion is the Dreyfus Model of Skill Acquisition. The Dreyfus Model doesn't explain skill acquisition at all. Its purpose is to classify learners into five slots, from Novice to Expert. According to the model, once you've attained the Expert level, rules no longer apply to you. You're a master of improvisation and your hunches are more valuable than weeks of earnest coding by those who follow the rules. Blah blah blah. This stuff is both offensive and wrong-headed. As it turns out, the text in which the Dreyfus brothers summarize their research is mostly supportable. It seems the model has been misused since then to excuse self-aggrandizement. The original Dreyfus paper is worth reading. J.D. says check it out.
J.D. Hildebrand has written hundreds of articles for dozens of publications and online communities dedicated to software development. He spent much longer writing this post than he expected to.