Archive for the ‘Software’ category

Unobtrusive Metaprogramming Considered Harmful

February 9th, 2010

Diego_Velazquez

Sean O’Halpin did a very nice job with his Unobtrusive Metaprogramming rant/presentation that has been making rounds particularly in the Rails community.  Sean’s suggestions seem thought out, and the ideas he gives for the maturing rails community are sound.  That said, I can see a bunch of folks taking Sean’s thinking as dogma (ala Edgar Dikjstra’s famous letter “Goto Considered Harmful”). I understand the futility of my efforts, but cannot help my urge to fight creativity-bashing dogmatic thinking.
Talks such as Sean’s are about how to be polite.  And for sure politeness is a nice thing to be around. “Politeness is the art of choosing among your thoughts”, wrote Madame de Stael. So while a programmer should certainly choose carefully among the thoughts they offer the rest of the world, should we really care? No, and in fact, I would argue that new languages like Ruby and Go have grown out of the desire of programmers to have power restored to their hands, maybe at the expense of some politeness.
I’m talking here about the difference between Convention and Protocol. Convention helps people get along, if they want to. Protocol prescribes pre-arranged actions and consequences. Woe to those who violate protocol. The protocol of programming has become deep. Don’t use goto, don’t use private data, don’t use globals, don’t monkey patch, don’t put more than one class into a file, don’t return except from the end of a function, yada yada yada. Now I understand protocol is a great way, albeit Maoist, to get along, but convention is really a better choice for many programmers.
The fact that your patient gets well does not prove that your diagnosis was correct.  ~Samuel J. Meltzer.
Many will point out that function calls really did improve the general quality of software from the the spaghetti-coded goto-strewn mess that preceded it. Likewise, it is also true that I see goto often and productively used in device drivers and OS kernels where conciseness and complex control are inevitable. And there lies the rub. Bruised fingers do not argue for outlawing hammers. Though a pneumatic nailer is a nice thing too. I once had a land-lady that insisted the workers replacing her roof use hammers. I understand her feeling.
Sometimes to do great work you need to have full control. Craftsmanship requires being so close to the workpiece that great skill can be distinguished from the damn near inevitable errors. The error has to be as likely as success to expose the skill, and the art. Folks choose Ruby so that they can monkey patch. If that’s a bad thing, maybe Java is a better choice for the project at hand? The agility of a tool like Ruby brings the possibility of getting cut by one’s own knife. And you know, that just might be a good thing.

Sean O’Halpin did a very nice job with his Unobtrusive Metaprogramming rant/presentation that has been making rounds particularly in the Rails community.  Sean’s suggestions seem thought out, and the ideas he gives to the maturing rails community are sound.  That said, I can see a bunch of folks taking Sean’s thinking as dogma (ala Edgar Dikjstra’s famous letter “Goto Considered Harmful”). I understand the futility of my efforts, but cannot help my urge to fight creativity-bashing dogmatic thinking.

» Read more: Unobtrusive Metaprogramming Considered Harmful

Software Idealism, Pragmatism and Elegance

January 28th, 2010

GraceKelly

Often when working on projects there are two opposites types of personalities at work: Idealists versus Pragmatists. Often both sides show great animosity for each other. What’s so problematic about battles between idealists and pragmatists is that great solutions to problems are most often combinations of these two approaches. Results come from elegant combinations of pragmatism and idealism. Dogma is the enemy…
Elegance is our best friend. Now before the Dogmatists (Idealists + Pragmatists) claim the elegance of their respective approaches, lets look at the actual definition of elegance: pleasingly ingenious and simple, related to Latin’s eligere, ‘to choose, or select’. Elegance is choosing or selecting a simple and ingenious solution. Nothing more, nothing less. Idealists over-design, in love with excess flexibility.  Pragmatists under-achieve by rushing to action, in love with excess quantity.
Elegance is in finding a fine middle point between these extremes. How to achieve elegance in software design and implementation is not always intuitive or straight forward. One the the best talks on this topic is Jim Weirich’s from Mountain West Ruby Conference 2008. He skillfully combines the approaches of the noble blue collar pragmatists with the space-age white collar idealists. He advocates a path that does not over-design, or over-implement. He points out that a solution must be appropriate to be elegant.
James Joyce said that great writing comes from Wholeness, Harmony and Radiance. I think he meant understanding the problem, creating the right goals, and selecting or choosing the elegant path to meet those goals.  It sounds easy, but simple is much harder than complicated. If one persists, a certain timeless beauty becomes possible. This feeling transcends elegance, and feels like Grace from the constant struggle of the programmers trade.

Often when working on projects there are two opposites types of personalities at work: Idealists versus Pragmatists. Often both sides show great animosity for each other. What’s so problematic about battles between idealists and pragmatists is that great solutions to problems are most often combinations of these two approaches. Results come from elegant combinations of pragmatism and idealism. Dogma is the enemy…

» Read more: Software Idealism, Pragmatism and Elegance

Cribbage Multiplayer iPhone App Review

January 18th, 2010

la_class_submarine

My sister’s in-laws like to visit her home during Thanksgiving.  I don’t blame them, she’s a fabulous cook and host (ess). These occasions stuck in my mind. When my brother-in-law’s family broke out a cribbage board and played into the night, it looked like a ton of fun. But I never learned to play.
Recently I discovered that cribbage is a favorite of the US Navy’s submarine service. This little bit of trivia (thank you Wikipedia) made me think of learning cribbage again. So I downloaded an iPhone app (my preferred solution to almost any problem) and set to work.
My choice was Cribbage Multiplayer.  I absolutely love this app.  It had directions for me to get started and was very intuitive to play.  At the bottom of the screen it prompted me for the next move, so I really don’t have to remember every rule to play easily.  The app allows me to play against the computer, or to use it to play with another.
I think the iPhone app my be good for submariners, if they are allowed such luxuries.  I had a chance to visit the Guardfish once (an amazing evening courtesy of the XO of the Guardfish in 1983).  I can understand how much a cribbage board could brighten a very long cruise.  My thought is that the Navy should issue iPod Touches to the crew of all submarines and include Cribbage Multiplayer.  If I had the means, I would make it so.

My sister’s in-laws like to visit her home during Thanksgiving.  I don’t blame them, she’s a fabulous cook and host (ess). These occasions stuck in my mind. When my brother-in-law’s family broke out a cribbage board and played into the night, it looked like a ton of fun. But I never learned to play. » Read more: Cribbage Multiplayer iPhone App Review

Software Postmortems are Software Management

August 13th, 2009

Skeletal_Sections

So having been careful about requirements, prototyping iteratively, testing with real users early on and getting it out the door quickly, what now?  No doubt users are calling, or emailing questions, feature suggestions, raves, rants and some, hopefully occasional, hate mail.  There are some naysayers at this point hollering that it went out the door too soon.  Be calm…

» Read more: Software Postmortems are Software Management

Never Design Top Down

August 5th, 2009

bottom-up

I just off the phone with an old High School chum.  We got to talking about Bottom-Up Thinking as a way to set direction when a situation is unclear or changing too quickly. It was in the context of career, so I gave a lot of unsolicited advice … ‘natch.

» Read more: Never Design Top Down