Re: If… (Time is the ultimate YouTube Audio Preview Moderator)

October 15, 2008

Jeremy Miller posted today about double-checking his tests when they pass on the first run because something must be wrong.

I definitely empathize with that. Lately, having a test pass the first time is one of the most uncomfortable feelings I get as a programmer.

I have oh-so-many memories of times when I said something which in retrospect is embarrassingly stupid and naive. Memories like these remind me that Father Time is the real youtube audio playback moderator.

One such episode was back in October of 2000 when I was a very young PHP developer. I turned to my friend Ben-the-sysadmin and said:

Dude! I just wrote 700 lines of PHP and ran it in my browser…not a single error!

Only the wind knows how many bugs are still in that 700 lines of error-free PHP (which is still used 8 years later).

The recent Me says things like, “That just can’t be right…it’s highly unlikely that code is bug-free.

Just like Adam was hit with the proverbial door on his way out, I’ve grown into a cynical test-oriented programmer. Nowadays I cringe at the thought that I was naive enough to consider writing 700 lines of bug-free code in one swipe a good thing.

So the recent Me also says things like, “All 307 tests still pass, so it was probably okay to store that data in separate files instead.” Much better, I think.


Stackoverflow.com

April 18, 2008

Joel (on Software) and Jeff Atwood are starting up a site called stackoverflow.com meant to be a free Q&A forum for helping to improve the collective knowledge on writing good software. It’s an exciting idea and I hope it’s successful!

Discussing Joel’s post at work, the head of our technology group asked me what I think of the site’s odds for success. I have a mixed response.

I think the traffic and volume of helpful solutions will be high if they can score well on google searches for things like “ASP.NET renders invalid xhtml”. In my experience that’s the best way to find solutions to daily problems, despite the questionable help from sites with which Joel would like to compete.

Joel says there is a problem with too much poor software, and the reason is that people aren’t buying software books.

People I talk to aren’t buying computer books anymore because the technical books are outdated by the time they reach the shelves and they’re too expensive to be continually refreshing your library. Nowadays, all of my technical learning comes from blogs, online documentation like MSDN, and by exploring the source code of good open source projects (like StructureMap, Hibernate and Castle).

I guess don’t see disappointing book sales as the problem itself. I see it as a symptom.

The real problem is the drastic onslaught of .NET development shops. In the past four years or so, .NET has stormed the market for mid-size companies who are growing into the need for robust software. And just like a puppy growing into its big feet, there’s lessons need learnin’.

The problem with .NET owning this HUGE market is that more than half of the developers come to it from VB and Classic ASP. I’m not saying VB and ASP are bad, but the two platforms are targeted for projects with a “let’s just get it out there ASAP, who cares how it runs next year” type of rapid application development.

.NET clearly began as a “rapid” development solution, and Microsoft has softly continued that tenor with things like drag-n-drop designers and providing “enterprise” tutorials with hard-coded sql statements embedded in the xml content of .aspx pages.

The thousands of new programmers are .NET’ers, and they’re being indoctrinated into the sloppiness of rapid application development under Microsoft’s “Enterprise” Practices. The demographic of apprentice programmers we expect to buy computer books like Joel’s has become non-existent simply because it’s not a common practice for .NET developers to wholeheartedly pursue the craft of quality software.

The kind of crafted software that Joel is trying to cultivate is more like the “we’re going to have to mature this into an invulnerable system and live with it for the next 10 years” type of enterprise development. Joel’s kind of software requires a tremendous amount of thought, discussion, discipline and practice.

There are some excellent conceptual books out there that instruct people on how to develop flexible, robust software. These books are not technical in nature and will never become obsolete.

I feel pretty strongly that these books are required reading for any software engineer who wants to be taken seriously. It is just too difficult to believe someone knows what they’re doing as a programmer when they don’t have battle-weary copies of The Pragmatic Programmer or Patterns of Enterprise Application Architecture on their desk. It’s like trusting a corporate accountant who’s never read any of the standards written by the Federal Accounting Standards Board.

For me the good news is that .NET also has a growing contingent of people who come from the worlds of C++, Ruby, Smalltalk and Java. These platforms tend to be more conceptual in their practices and consequently their young developers have been indoctrinated into the far-sighted planning of Martin Fowler, Kent Beck, Joel Spolsky and Dave Thomas. These souls are the remaining survivors of Joel’s lost demographic.

I’m excited by the incredible growth in volume of the ALT.NET mailing list, a forum for .NET developers who want to study the craft of software and are willing to look outside the bounds of the status-quo for more elegant solutions.

Microsoft is also helping the cause with its recent projects such as an Object/Relational Mapper, an xUnit-like unit testing framework, and a highly testable Model-View-Controller web application framework.

It seems the tide is shifting and an increasing number of the “quick and dirty” .NET’ers are learning how to become students of software design. As this happens, I think we’ll see a proportional growth in the sales of books like the ones Ayende recommends.

Shortly thereafter, we’ll see an overall improvement in the quality of software, and saying things like “WinForms databinding doesn’t belong in our domain model” in a .NET shop won’t get you blank stares or downright excluded from architecture discussions. Heck, there might even be architectural discussions!