Live data from Hacker News

The Duct Tape Programmer

joelonsoftware.com

11–20 of 123 posts

Re: The Duct Tape Programmer

#11

Maybe Netscape's duct-tape programming had some side-effects though... http://www.joelonsoftware.com/articles/fog0000000069.html

A consequence of those rewrite side-effects:

Mozilla Firefox was forked from the rewritten Mozilla codebase

> Netscape 6.0 is finally going into its first public beta...Well, yes. They did. They did it by making the single worst strategic mistake that any software company can make: They decided to rewrite the code from scratch.

http://www.mozilla.com/en-US/firefox/releases/0.1.html

http://www.mail-archive.com/linux-users@linux-sxs.org/msg067...

Re: The Duct Tape Programmer

#12
I agree with the basic idea, but I think Joel is going over-the-top with the C++ hate. I've actually shipped real code that used the insanely complicated feature of C++ templates. Works great.

The problem is not with a specific language or technology -- it's using the bleeding edge technology, when the boring one will do.

Re: The Duct Tape Programmer

#13
"One principle duct tape programmers understand well is that any kind of coding technique that’s even slightly complicated is going to doom your project."

Like writing a custom compiler for your web app?

http://www.joelonsoftware.com/items/2006/09/01b.html

After he jumped that shark I don't read anything he writes anymore.

Re: The Duct Tape Programmer

#14
"He is the guy you want on your team building go-carts, because he has two favorite tools: duct tape and WD-40."

This phrase comes from watching too much Eastwood (Gran Torino ~ http://www.imdb.com/title/tt1205489/) The idea behind it is you can jury-rig/fix almost anything with WD40 & duct tape alone without the need for fancy expensive tools.

Re: The Duct Tape Programmer

#15
post #10

"Any kind of coding technique that’s even slightly complicated is going to doom your project." "They xor the 'next' and 'prev' pointers of their linked list into a single DWORD to save 32 bits, because they’re... smart enough, to pull it off." How is that not even slightly complicated?

The Kolmogorov complexity of COM is, at the very least, hundreds of kilobytes of itchy, fidgety, sensitive, and complicated code. The Kolmogorov complexity of xor'ing two pointers to save 32 bits is on the order of tens or hundreds of bytes. (I'm using the term a bit loosely, obviously, but I think it gets the point across.) I suppose it depends on the limit of "slightly", but in context I think it's clear we're talk…

I see what you're saying, and I agree. It's not comparable to COM.

I think the thing is, articles like this tend to create some idealized programmer that is just a conglomeration of attributes the author likes even if they are mutually exclusive. To me, avoiding complexity and doing bit manipulation are mutually exclusive.

It's like saying you should use left shift (or is it right...?) instead of diving by 2. Ok, it may be faster. Or the compiler may just do the same thing regardless how you type your code. The point is that "/ 2" means divide by 2 to anyone at all familiar with code. Unless you have some really compelling reason to do otherwise, you should use "/ 2".

Using shifts for division (or various other bit manipulation) may be how your idealized programmer shows their classical training, but don't kid yourself into thinking that bit manipulation fits into all your other ideals for programmers.

Joel's idealized programmer also avoids unit tests. Are you serious? How can this possibly be a good idea? No, your customers don't care if you wrote unit tests... in the same way you don't care if your architect does whatever it is architects do to ensure the accuracy of their work. But that's just the point. You don't care (nor should you) about how they ensure accuracy. You care only that they do. So no, your customer doesn't care if you wrote unit tests, but I assure you they care if your software crashes or gives inaccurate information.

Of course, no one ever creates an idealized programmer without creating their opposite. Joel's "ideally" bad programmer multiply inherits from 17 sources. Does any sane programmer really do this? No. Of course not. Why bother mentioning it? It's like saying an idealized pilot is not like those other pilots that intentionally crash their planes. Well... no one intentionally crashes a plane. Don't bring up absurd examples to prove your point. If real life doesn't prove it, then it's not a valid point.

The simple fact is that when I look at my own real-life, deployed-in-production code, I find this: The code I wrote just to get a problem solved in whatever way possible (duct tape) becomes more and more of a liability as the requirements change. With the code that I spent the most time designing (assuming I eventually came up with a good design), the more the requirements change, the more I see the beauty of the design. When a change in requirements can be fixed with a find/replace, it's a job well done. Duct tape code leads to duct tape maintenance. Duct tape maintenance leads to thedailywtf.com.

I have no problem with emphasizing the importance of shipping software. I have a problem with people saying "real programmers use butterflies" when they aren't writing a web comic.

I don't think there's a single "real programmers" article in the universe that is internally consistence (doesn't advocate any mutually exclusive practices). Like I said, it's an ideal, an ideal constructed out of everything the author could find in their mind, whether it fits together or not. This wouldn't be a problem if the author admitted even a slight possibility of exaggeration or lack of internal consistency, but they never do.

Now... I think by now I've probably exaggerated and broken internal consistency enough for one day, so I'll stop here.

Re: The Duct Tape Programmer

#16
I call bullshit. I've worked with some "just get it done programmers'. Have you tried to go into code that someone threw in to just make it work.

Abstraction, interfaces and unit tests are not a leisurely activity for academic developers. We use them to make the code less complex and maintain. The cost of development isn't the initial code base, its the fixes and additional features people want AFTER the initial release(s). Going back into the code and safely making changes or adding code with these in place reduces time.

I had an application without automated testing, it cost the company almost 2000 man hours to test the system every time they made a release.

Design patterns, Joel, are repeatable patterns within code. Design patterns are again to help when another developer goes into the code they can see what the heck the original developer tried to accomplish.

To summarize, I would suggest you out source some code to the far east. They will get it done really fast for you. And yes it will only work 50% of the time. I love buying products that will only work 50% of the time and unfortunately I don't get to pick which 50% works.

Re: The Duct Tape Programmer

#18
> A 50%-good solution that people actually have solves more problems and survives longer than a 99% solution that nobody has because it’s in your lab where you’re endlessly polishing the damn thing. Shipping is a feature. A really important feature. Your product must have it.

I think this does matter.

Re: The Duct Tape Programmer

#19
Just remember that this principle applies doubly if you're a startup.

And it applies doubly again if you're an early stage startup, because you're still deciding what to build at that point. Astronaut architecture is a complete waste of precious time that you don't have.

Re: The Duct Tape Programmer

#20
"And unit tests are not critical. If there’s no unit test the customer isn’t going to complain about that.”

By all means, ship. Do what you gotta do. But a code base that doesn't have tests cannot safely be refactored. This technical debt must eventually be paid by the product owner in cash and the code's maintainers in sanity.

Post reply on HN