97 Things Every Programmer Should Know

(Chris Devlin) #1

Collective Wisdom from the Experts 173


The interplay between two code defects that appear as one visible fault not
only makes it hard to fix the problem, but also leads developers down blind
alleys, only to find they tried the right answers early on.


This doesn’t happen only in code: the problem also exists in written require-
ments documents. And it can spread, virally, from one place to another. An
error in the code compensates for an error in the written description.


It can spread to people, too: users learn that when the application says Left, it
means Right, so they adjust their behavior accordingly. They even pass it on
to new users: “Remember when that applications says ‘click the left button,’ it
really means the button on the right.” Fix the bug, and suddenly the users need
retraining.


Single wrongs can be easy to spot and easy to fix. It is the problems with multi-
ple causes, needing multiple changes, that are harder to resolve. In part, this is
because easy problems are so easily fixed that people tend to fix them relatively
quickly and store up the more difficult problems for a later date.


There is no simple advice for how to address faults arising from sympathetic
defects. Awareness of the possibility, a clear head, and a willingness to consider
all possibilities are needed.

Free download pdf