Wisdom Of Pascal

Wisdom Of Pascal

“I would have written a shorter letter, but I did not have the time.”

Blaise Pascal was a smart dude. Much of what he had to say is surprisingly applicable to software development (which is why if you show me a well-read developer I’ll show you a good developer). The above quote came to mind yesterday during an all-hands meeting where we were discussing our company core values:

“We build elegantly simple software.”

I love that sentiment. But make no mistake: elegance and simplicity take more time to build than complexity. This is true up and down the process, from prototyping, to requirements development (holy cow is this step often rushed; we’d do well to heed Mark Twain here), to implementation and testing.

My first task after moving to San Diego was to help a development team push through a particularly challenging set of features for a digital mapping system. Twelve hour days and weekend work was expected, and all tasks had to be done as quickly as possible. The technical architect had put together a mockup of a few of the screens using a prototyping tool, and unfortunately the quickest way to make those screens a reality was to copy and paste the auto-generated XAML (sort like Android’s XML-based UI markup, but for C#) and then tweak it. This led to a ton of duplication, with hard-coded screen positions everywhere. By the time we got the initial release of the application to the test team, it had become an unmanageable nightmare. But we limped along, duct taping bugs as they came up.

Then came the back-breaker, under the guise of a single requirement: “by the way, this needs to work in landscape as well as portrait orientation”. Just like that, our brittle implementation became untenable. It needed a complete re-write.

I was assigned the task, and (thankfully) given a month to do it. My delete key was never busier as I learned how to abstract and consolidate the XAML, replacing tons of repeated values and cleaning up duplication. Turns out XAML is pretty easy to author and has plenty of features for writing clean and responsive implementations, but no one had bothered to learn it. By the end of my process, in addition to adding a landscape capability, I’d shrunk the code base by over 90%, and gained a near 5x boost in performance to boot.

The moral of the story? Well, actually there’s two. The first is that using SLOC is a dumb measure of productivity (I was averaging about -10,000 lines written per day or something like that). And the second is that the best developers delete as much code as they write. Maybe even more. Refactoring isn’t a separate step on the task list; it’s part of every task. Yes it takes more time. Yes you might need to let go of your ego and trash that super clever function when it becomes unneeded. But your product will be better for it.

Pumping Iron

Pumping Iron

When I created this blog a couple of years ago, I’d been inspired by Soft Skills, a book of general life advice for software developers. It covered a range of topics, but one that particularly caught my attention was a recommendation to build an online presence through writing, primarily as a résumé building exercise.

That made a lot of sense, but I didn’t stick with it for long, perhaps because I wasn’t in the job market at the time. Nor am I now. So why the revival?

Part of that had to do with a conversation I had with our UX designer about domain names, which reminded me of how happy I’d been to snag this one. But the biggest reason was a side comment made in Joel Spolsky’s four-part series on writing effective software specifications:

Writing is a muscle. The more you write, the more you’ll be able to write. If you need to write specs and you can’t, start a journal, create a weblog, take a creative writing class, or just write a nice letter to every relative and college roommate you’ve blown off for the last 4 years. Anything that involves putting words down on paper will improve your spec writing skills.

The average software developer needs to write more than what you might expect, and those who do it well are rare. I want to be among them.

Say Hello

Say Hello

I checked my site statistics yesterday, and to my surprise, I actually had some visitors. The majority came from Twitter, which is funny because I don’t tweet except for when I post here.

Could you do me a favor? If you’re reading this, leave a quick comment so I know who’s reading. Thanks!

The Human Element

The Human Element

It’s been nearly two years since I became an official “manager” of software engineers. While it comes with its share of challenges, I find it more fun than I’d initially expected (it doesn’t hurt that I still have time to write code).

Software development has a reputation for being the domain of anti-social nerds who work in isolation on esoteric technologies with scientific precision. But the truth is that human beings write software, and development is just as much an art as it is a science. Each engineer brings his or her own unique skills, personality, and craftsmanship to a product, and the result bears that image.

The best software projects are those that recognize this and use it to its full advantage instead of fighting against it with process and policies that seek to stamp out individuality at the altar of predictability. It’s a self-defeating approach, at least until the time when AI can write good code (and if that happens, we’re all doomed anyways).

Only tangentially related, but this is the best article on software development ever written. Until tomorrow?

I’m Back?

I’m Back?

Two weeks ago my credit card number was stolen. What a pain! But one of the happy consequences of going through the past year of charges and updating all my auto-pay items was the rediscovery of this website.

What’s changed in the nearly two years since I last posted? A lot and yet not very much. So I won’t bother with a play-by-play. Instead I’ll tell you a few of the things I’m working on now, each with a coolness factor (5=super awesome, 1=lame)

  • Node.js (3)
  • Docker (4)
  • Kubernetes (4)
  • Gitlab CI (4)
  • Amazon AWS (4)

Hmm, I rate my technologies like I rate my beer: most of it’s pretty cool, but rarely do I give out a minimum or maximum score. I wonder if that’s a consequence of being a Nine on the Enneagram. Which reminds me that I need to request this book from the library. . . . and done.

Wow, this has been pretty stream of consciousness. And not as difficult as I’d thought to write. Perhaps I’ll do it more.

The Holy Grail

The Holy Grail

As of today, I do not think there is a better general purpose language in existence than Python. With few exceptions, it just feels “right”, and without fail writing it makes me happy. Here’s just a couple of my favorite features:

Clean syntax

Python eschews block delimiters in favor of strict indentation rules, which both keeps the code more readable, and forces good formatting. It also requires a minimum of special characters, enhancing readability even further. I work with Perl extensively in my day job, and just look at how much grosser it looks than the equivalent Python:

if ($enemy == 'klingon') {
   firePhasers();
}
else {
   openHailingFrequencies();
}
if enemy == 'klingon':
    firePhasers()
else:
    openHailingFrequencies()
Implementational flexibility

I’m not sure that’s actually a word, but what I mean to say is that Python is a solid choice no matter the design approach you want to take. Writing a simple procedural script? Python does that. Taking an object-oriented approach? Python does that too. Want to dabble with a functional style? Oh yeah, Python’s got your back.

While the purists might say Python isn’t the ideal choice for any of those scenarios, I say it’s probably good enough, and in the real world I’d rather be an expert in one language than a novice in three.

Extensive PACKAGE library

I’m continually amazed at how much functionality is included in Python’s standard library. It makes writing code so much quicker. And if a feature isn’t in a default package, there is a massive ecosystem of third party libraries.

In my next couple of posts I’ll share a few of my favorite of these packages.

To Be Fair

Python isn’t perfect, and there are a couple things I don’t care for. For example, take its ternary syntax:

action = 'punch' if captain == 'Kirk' else 'talk'

I’m generally a fan of ternary operators because of their concision (which is a word I just learned), but the ordering of this construction feels awkward. See, I can be unbiased!

Hello world!

Hello world!

“The making of things is in my heart from my own making by Thee.” – J.R.R. Tolkien

Hi, I’m Jud. It’s been several years since I’ve blogged consistently, but having been inspired by John Sonmez’s Soft Skills, I’ve decided to get back in the game.

The blog title comes from the story of the creation of the dwarves by Aulë in Tolkien’s The Silmarillion. I love the idea that as God’s image bearers we are to called to be sub-creators in the universe He has made. Though we often fall short of His ideals, somehow He still graciously accepts our work.

Specifically I see my calling in the area of software craftsmanship, and thus I expect topics here to hew fairly close to the world of programming, though I’m not promising there won’t be a few rabbit trails from time to time. Hopefully what I write here will be useful to some, or at least mildly entertaining.

And with that, time’s up for today. Tomorrow expect my first “real” post, on why I love Python.