30 April 2008

Software Estimation Considered Harmful

problem

"So how long do you think it's going to take?"

We've all been asked the question a thousand times and more. Project Managers, Client Liaison, Salespeople, Marketing Managers,... they all want to know. And we, like sheep, like the suckers we are, because we try to please (you try, too, please!) suck hard on our spacebar-calloused thumbs, and guess.

"I guess a couple of days."

"A week."

"Three months."

"A year; maybe 14 months."

Nobody really trusts those really long guesses, though, so that's where the project management experts get involved, break the task down into itty, tiny bitty little bits, parallelise them, ALAP, ASAP, lead and lag. And then we all sit down around a table, and for each and every one of the itty tiny bitty bits the project manager asks the dreaded question.

"So how long do you think that one's going to take?"

The Real Answer, the Truest Truth, is, "I don't know." Perhaps a tiny voice deep inside our soul cries out, "I don't care! It is going to take as long as it takes." But for mysterious reasons all tangled up in our wetware, all tied up in the social hierarchy dynamics of the human ape and those twisty strand of ribonucleic acid in our hardware, "I don't know" marks me as less-than-competent. And "I don't care" is career limiting; "Not a team player. Fails to identify with the organisations goals and ethos."

So we guess, and we guess, and we guess again. And we're (almost) always wrong!

For 50 years we, as a craft, as an industry, have been guessing wrong. For 50 years our projects have mostly finished "late", and we keep wondering "Why?" Books have been written, Methodologies developed, PhDs awarded, Management Disciplines imposed and entire Consulting Industries built on the premise that it is ''possible'' to estimate software effort better than we presently do. Or, if we can't estimate better, then we can manage the estimation risk better. Or the process. Or those pesky damn programmers.

All in vain. The projects keep coming in late.

where it all comes from

How did this abysmal state come about?

I think it is rooted back in the 1950's, when the first Big Software projects were undertaken, most notably by the US military. Quite naturally they applied the project management strategies that have worked for them since time beyond time. Strategies that have successfully built forts, dug moats, laid siege to cities and moved large numbers of soldiers across continents and seas. The trouble is that those are extremely well understood problems that have been solved thousands -- millions -- of times, ever since Akkad invaded Ur. For such classes of problems, estimates of time and effort are pretty reliable. If you're a logistics planner, an army engineer, you know, from loads of practice and handbooks distilling five thousand years of experience, just how long it takes for a boatload of soldiers to move a given distance, and just how much food, water and fuel they need along the way.

"Where there are in the field a thousand swift chariots, ten thousand heavy chariots, and a hundred thousand mail-clad soldiers, with provisions enough to carry them a thousand ''li'', the expenditure at home, including entertainment of guests, small items such as glue and paint, and sums spent on chariots and armour, will reach the total of a thousand ounces of silver per day."
-- Sun Tzu, ''The Art of War''
It is an extremely well understood problem domain!

Software development is a different sort of beast. It's all new to us. Amost every problem has never been tackled in its entirety before. I don't claim that software development is unique in this; I am pretty sure that developers of new aircraft, ship engines, new forms of bridges, all face the same problems as software development. What -- perhaps -- distinguishes software development is that it's all new every time! We never get to repeat our past developments. If we were repeating -- exactly -- repeat-developing a requirement -- in every detail -- we would already have the code and we'd have no need to write anything! And if there's one thing I've learned about developers, its that we -- most of us -- hate doing the same thing twice! It's probably a function of our predisposition towards ADD/ADHD.

all change

But, no! In truth there are always differences between the Systems That Have Gone Before, and the Systems We're Developing Now. Even if you've developed interface to a dozen payment gateways, 100 gets you 1 that the next payment gateway has some unique characteristics all its own. Or perhaps some key technology has undergone a significant change in the last few years. Or some new tech has crept into the picture. "Our service is provided through a RESTful API"...

Then, too, how do you account for the Buggerance Factor. Murphy's Law. The simple fact that even the simplest piece of software depends on a ''huge'' number of other bits'n'pieces being in exactly the right places, configured exactly right, at exactly the right time?

I should not have had to spend an hour this morning tracking down the fact that a key library -- a jarfile that should always exist in a standard, accessible place -- had mysteriously been Taken Up. Vaporised. Gone. Perhaps my disk is going flaky? It shouldn't have happened. I should not have wasted an hour figuring out why the application wouldn't run. But I did.

I should not have spent a morning last week discovering that, despite the Vendor's persuasive assurances to the contrary, the version 8.2 driver does emphatically not work properly with the version 8.1 server. Let us not even ask the question, "Who installed the 8.2 driver?" A fruitless waste of time, energy and stress hormones.

How the hell do you predict that particular morning and figure it into your time and effort estimate? Or the half-day spent figuring out that there's a bug in a key data-access library you're using (and it's not your choice that mandated its use, but some arbitrary "policy".) And then another hour figuring out a way to work around the bug. Just how exactly, when you're Project Planning some 4 months ahead of a frustrating and unproductive morning, do you predict those?

You just blew your estimate.

managing estimation risk

I am well aware of various approaches to software development that try to futz around the problem -- some of them with some marginal success -- by giving up the idea of a project being "finished". But nobody seems willing to confront the central problem head-on.

Estimating "How Long It Will Take" is a Broken Idea.

Like the drunk looking for his spectacles under the streetlight "Because that's where I can see to look for them" we keep searching for ways to make estimation more accurate, more reliable, more amenable to conventional management thinking. What we really need to do is screw our courage to the sticking point, and accept that there is, really, honestly, truly, no alternative:

We must completely abandon the whole concept that software effort is amenable to estimation at all.

call to arms

Give up the crutch!

The next time -- and every time after that -- that someone asks you "So how long do you figure that's going to take?" -- "So when do you think we can go live?" -- Just Say No!

Just say, "It will take as long as it takes."

I guarantee you some excitement in the short minutes immediately following, but let go of your fear! Immediately you will find yourself skulling in the calm pond of assurance and truth that lies beyond the fear. Live and enjoy this Truth, for it will set you free. If other people want and need to make deadline commitments, let them be the ones to suck their thumbs, making up fantasies and lies. Do not allow them to push that responsibility onto you. Don't allow them to turn you into the liar. Just tell them,

It takes as long as it takes. It always does, anyway!

25 April 2008

Quotable

"The Ark was built by one man.
The Titanic was built by a team of professionals."

20 April 2008

Wizzards

Programming software is Magic.

I don't mean that there's something mystical about it, nor that it is intrinsically inaccessible to ordinary people. Nor (I emphatically add) do mean that it is like Magic. In every aspect I can think of, the act of Programming software meets all the criteria for performing Magic. Magic in the Swords and Sorcerers or Unseen University sense. "Alakazam!" and the Prince turns into a Frog. "Shazam!" and you're whisked away to a far, far place at high speed.

Just look at the facts: We (programmers) write programmes -- spells -- in arcane and cryptic symbol languages unknown to the common mob.  Get the slightest part of the spell wrong, and, at best, it fails utterly to do anything.  At worst it runs amok and fearful consequences ensue -- fires, floods, loss of money and even life!  Get it just right, in every teensy, tiny, ball-aching, nit-picking detail2, and Lo! out of nothing, stuff happens in the real world.  Gold changes hands.  Trains run on schedule.  Music plays and Feyries dance1.

Where nothing was before the spell was cast, something comes about solely because of the spell.  That's Magic.

And, just like in the fantasies where Wizards keep pet Dragons and dribbly candles set atop skulls are the acme of interior decoration, programmers frequently work at odd hours, with intense, monomanic concentration bordering on the inhuman.  And, like the traditional Wizardly Schools, programmers are admitted to different schools of various arts and degrees.  So we have Clerics -- programmers content to churn out the boilerplate code needed to keep the wheels of commerce (and most web applications) running, but lacking any true proficiency with martial weapons of higher degree; Monks -- who eschew the use of particular weaponry but, ninja-style, willingly embrace whatever comes to hand as combat fodder; Wizards -- capable of serious Magic, but forget their spells once cast, capable of wonderful stuff, but doomed to repeat it -- with minor variations -- time after time; and then there are the Sourcerers -- Masters of The Source3 whose code is so elegant and expressive, so parsimonious and pretty as to make brave Programmers weep with envy and admiration.

No, you can not deny.  Programming really is the realisation of the ancient idea of Magic.  Say the Magic Spell and Change Reality.

[1] Well, anybody who wants to dance, I suppose, really.
[2] ...and My God, there's an inordinate amount of crappy detail that all has to be Just So!
[3] Waves to Ken, Doug, Dave, Jason, Paul, Johan, Bob, Brian, John and several dozen others...

15 April 2008

Bad. Punctuation,

Tripped across this little quote on /. this morning:
A Linux machine! Because a 486 is a terrible thing to waste! 
-- Joe Sloan, jjs@wintermute.ucr.edu
Alas, I can clearly see that somebody screwed-up the punctuation.  Surely that should read
A Linux machine! Because a 486 is a terrible thing. To waste!

26 March 2008

SABC's website sucks

Email to info@SABC.co.za:
"Why does SABC's website suck so badly when viewed in Firefox?

"Not to mention that it is completely unusable with Javascript disabled, which renders it inaccessible to people using Braille readers or text-based browsers of any kind; this violates the constitutions provisions against discrimination."
BTW: if you leave off the "www." prefix, you get to see exaclty what software they're using to drive their (very b0rked) portal.  Now I'm not suggesting that this might render them susceptible to getting the portal cracked, but anybody who has set up a portal server that incompetently has quite possibly left some default logins/passwords in place.  Maybe?

Not that I'm suggesting anything, mind...

01 March 2008

User-interface Reboot

This article by Mr Mirchandani gets it exactly right: UI again ...don't pretty up, destroy!

I have never forgotten the experience of early last year. Our car had been stolen, and we were jumping through the licensing department's hoops to get the old car de-registered, and our new car registered.  Well, 10-year-old, 2nd-hand car, since that's all we could afford with what the insurance company deigned to pay out -- another saga for another day.

First we could not de-register the old car, because it was flagged on the licensing system as "stolen", so no changes to its details are permitted.  WTF?  We could not unflag it, since that would require the police to mark the car as recovered, complete with verification of engine, chassis, VIN and registration numbers.  Eventually we left the matter in the hands of one supervisor who took pity on us as I crumpled in the face of this actively-hostile "information" system.  She solved the impasse by going outside the system: phone calls to a special contact in Pretoria -- "high friends in low places."

Then we had to register the new car.  The details had to get captured no less than 5 times!  Twice, manually by myself, the remainder by the clerk punching a terminal.  And two of those instance involved recapturing the vehicle details from a form still-hot from their system's laser printer.  The system already had the details, yet they still had to be manually recaptured.  This is insane!  Weren't computers supposed to save us work?

23 February 2008

As BAD as Some can be, Others can be GREAT

We interrupt the on-going diatribe between my self and Datapro/Vox Telecom[1] to bring you Good News for Modern Persons.

In the supermortal words of Hubert Farnsworth, "Good News, Everyone!".

Last eve some mishap caused my DSL model/router to disconnect.  For some while it failed to reconnect: AUTH_FAIL, it said.

Now, my ISP, WebAfrica, whom I hold in very high regard, has been having an occasional little trouble in recent times with their authentication servers.  So: patience is the order of the day.  It was quite late in the day, so my bed called, nothing in my little local network really needed Internet access overnight, so I left matters until the morning, in the hopes that the problems would be resolved without any input on my part.

They were not.

So... Onto the phone this morning.  Less than two rings!  (Contrast this with giving up after an hour on hold last week with Telkom!)  Spoke to a chap who was remarkably candid: "Yes, we have had a problem, and a few accounts seem (for reasons we don't fully understand, yet) to have been stuck in an "inactive" queue.  We're terribly sorry.  I am sorting it out right now [clickety clickety clickety click]; would you like to hold?"

I declined to hold.  The pain of being on hold to Telkom being too fresh in my psyche, I suppose.  After suitable pleasantries I hung up.

A couple minutes later the phone rang.  Same chap from WebAfrica.  " I see that your modem seems to be having some trouble connecting.  Could we please confirm the password it is using to connect...?"

Well, Bugger Me Sideways With A Spoon!  Not only did WebAfrica's support guy sort the problem out instantly, with an ordinary, human-to-human acknowledgment that something had, indeed, gone wrong, but, after I had explicitly said "Ticket closed; I'll call you if there is any further problem." had monitored the situation to make sure that I -- The Lowly Customer -- had been properly sorted out, and called me back to make sure of it!

What am I saying, here?
  • I could have raved about not being kept on hold in some support-queue for an hour or longer.
  • I could have raved about the great service I received during the handling of my support call.
  • I could have raved all night in San Fransisco with the hot chick on her way to Hawaii (but that's another story!)
This guy -- unasked for -- stayed attentive to my little problem until he was as sure as he could be, that it had been solved to my satisfaction.  Not his.  Not Webafrica's.  Mine.

Here's a significant point: None of us (modulo the Absolutely Bloody Minded) is so stupid as to believe that everything Works Flawlessly All the Time.  Shit Happens.  We know this.  When it does, please don't lie to us and use phrasing designed to imply that we, the Customer, are Stupid, Insane and/or Lying!  Please don't pretend that it is Somebody Else's Fault or an Act Of (somebody's) God. (Hello, Telkom!)  If you've fucked up, admit it, apologise, and move on. Nobody will hold it against you.  In fact, given the current climate of Assumed Corporate Infalibilty, we'll sympathise and likely offer to help you fix it!

Just say "Yes.  We Had a problem.  We've fixed it. (OR: Here's what we're busy doing to Fix It.)  We're sorry."

If it is a significant proportion of the working day, offer a credit for the lost service time.  Not difficult, is it?  Not Rocket Science!
I cannot think of a way to praise this enough!

This most recent incident is the perfect exemplar of the sort of brilliant, attentive, honest service  I have unfailingly received from WebAfrica!  I have had a friend[2] phone me up especially to say, "Thank you for putting me on to WebAfrica as a service provider!  I've since recommended them to at least 15 other people!".

I kid you not!

If anyone in South Africa wants or needs ADSL service, Internet access or web-hosting, do yourself a favour: www.webafrica.co.za

Their rates are amongst the lowest around.  Their service is out of all proportion to what you pay!  (i.e. It's brilliant!) If they ever get bought out by Vox Telecom I shall probably have to leave the country -- and even then I won't find an ISP as good!

[1] A "keyboard/finger" interaction nearly made that "Pox Telecom", whIch would have been appropriate...


[2] We've known each other over 35 years, now... I think that qualifies as friendship, no?
Related Posts Plugin for WordPress, Blogger...