97 Things Every Programmer Should Know

(Chris Devlin) #1

Collective Wisdom from the Experts 57


Needless to say, whenever something went wrong in applications based on this
class, they vanished like Mafia victims at the dockside, leaving behind no useful
trail of bubbles to indicate what the hell happened, notwithstanding the dump
routines that were supposedly called to record the disaster. Eventually—a long
eventually—we took stock of what we had done, and experienced shame. We
replaced the whole mess with a minimal and robust reporting mechanism. But
this was many crashes down the line.


I wouldn’t bother you with this—for surely nobody else could ever be as stupid
as we were—but for an online argument I had recently with a bloke whose
academic job title declared he should know better. We were discussing Java
code in a remote transaction. If the code failed, he argued, it should catch and
block the exception in situ. (“And then do what with it?” I asked. “Cook it for
supper?”)


He quoted the UI designers’ rule: NEVER LET THE USER SEE AN EXCEP-
TION REPORT, rather as though this settled the matter, what with it being
in caps and everything. I wonder if he was responsible for the code in one of
those blue-screened ATMs whose photos decorate the feebler blogs, and had
been permanently traumatized.


Anyway, if you should meet him, nod and smile and take no notice, as you
sidle toward the door.

Free download pdf