The Serial Killer

A little over a year ago, I decided to write my own Serial Terminal.  Most people’s reaction to this is “why?”  Serial comms is a technology well on its way out, and what they see as the critical hit, a bunch of terminal programs already exist.  Many of which are even open source.  So why would I bother?

Read more of this post

Advertisements

Software is like Cooking

In a previous post I mentioned that software development is a creative process.  In this post, I’m going to expand upon that a little, add some metaphors and later, if I’m feeling wild, I might even add a simile or two!  I’m sure F. Scott Fitzgerald is turning in his grave, given that I knowingly “laughed at my own joke” then.

 Coding is like cooking.  It is important that the flavours blend together to look and taste like they are part of a single entity.   It’s not really ideal to find a whole lemon buried inside a cake.  Or a stew.  Sadly, I see this kind of thing all too often in coding.

The recipe calls for a hint of lemon, so Engineers being Engineers, think “if a hint of lemon is a good idea, then think how awesome it would be if we had a whole fruit in there, from which we could squeeze the right amount of lemon juice from whenever we wanted.”  At which point there is now a lemon bolted on the side of your mixer and you find that when you try and bake a different variety of cake, the machinery forces you to have lemon in there.  Or more likely, it is a multi-flavoured juice dispenser, which is so heavy the mixer can barely stand up on its own any more.  And it leaks.

Which doesn’t at all lead me to my next point, so I’ll just jump to it awkwardly.  Something I find myself doing quite a bit is cooking blind.  Which is ironic, because sight is the main sense I actually employ when doing this.  What I mean by that, is that I don’t taste my food before serving.  It’s a bit inexact, and I admit, also somewhat hit and miss.  And largely, when it’s a hit, it’s due more to experience of knowing the right colours, textures and combinations of flavours that work.
So I guess what I’m saying with this post is dressed up prettily, but blindingly obvious.  Experience mitigates some of the worst sins, but if watching altogether far too many cooking shows on telly has taught me anything at all, it’s that life is infinitely better if one tastes food before it is served.

Reviewing review

Code review is something that nearly all software developers consider to be a good thing. Though frequently when I’m doing it, I feel out of my depth.  This is usually when I’m learning the technology or codebase.  And recently I’ve been reviewing not just an environment in which I am comfortable (a desktop application) but also a web application, which covers the whole stack right from database, webservice, client and javascript-based webpage.  My experience to date has been in embedded software, desktop configuration software, a network-based build server and a smattering of almost static html, so I’m feeling somewhat out of my depth when asked to cast an eye over a SQL stored procedure.
Read more of this post

Yours, sincerely embarrassed

Last week a ghost of christmas coding past came to haunt me.  Some code that I wrote two years ago was found to be broken.  I’m not surprised.  When I first heard about the issue, despite the fact that I no longer work in that team (or indeed on that code base, language or even CPU instruction set) one of the first things I did was pull up the code to take a look.

This particular area of code is quite neglected and I knew for a fact that other people had only touched it in passing, without needing to make the modifications needed for real understanding.  I’m not saying that other people couldn’t understand it, but as a release was due to happen the following day and that, despite the bug being two years old, when the symptoms are described, it sounds quite scary and speed was going to be important for fixing it.  About 1 in 20 times our security handshake would fail.  The legitimate user would be temporarily unable to configure the product.  Because of this, an impending release (due to be finalised the following day) would be put at risk.  So my experience in this area meant that I could immediately narrow the bug to two or three files in the whole repository and I knew more or less how they fitted together.  Speed boost, achieved.

Read more of this post

The Bad Time

Well.  I’m nearly five (I’m secretly waiting until I can start quoting A.A.Milne!) but the inevitable has finally happened.  My workplace is going through some “structural changes”, shall we say.  For the first time in my career, people I know and respect are losing their jobs around me.  I don’t want to go into my opinions of the specifics of the decision as I don’t have the full picture.  I certainly don’t have the whole set of numbers nor the strategic view.  But rather, I want to go into the emotional side of things.  Because actually, it’s quite a scary time for everyone involved.

Many people have been saying that the writing has been on the wall for a long time.  Certainly the sales data sent through on the internal financial reports haven’t been painting a rosy picture at all.  Given that this is my first time experiencing this level of staff redundancies, and ones so close to home, I can’t say with any kind of truthfulness, that I saw this coming.  I honestly believed that we would weather the storm and that because we are bidding for several large contracts at the moment, that we’d all be breathing a big sigh of relief sooner, rather than later, that we’d be in good shape again.  Apparently not.

Read more of this post

Big Up Front Design Considered Scary Beyond All Belief

I had never before been able to put into words why I really hated it when a senior developer (Mr X) I worked with demanded I had a Big Up Front Design before I wrote any code, but I knew it irritated me to the core.  Because Documentation is a Good Thing™ right? Except that I am now trying to work alongside someone on a particular project (whom I shall call Mr Y), who is still under the influence of said senior developer.  I’m trying to help Mr Y  to produce a design which will satisfy Mr X so someone can eventually get around to the task of implementing the thing.

I’m not saying all design is bad, far from it!  I just think that most capable developers are really creative people who like to battle with the machine.  They are, in my humble opinion, considered capable because they’re constantly analysing their design and making tiny adjustments where necessary.  Even tiny things like changing that function parameter to be “const” because we’re not modifying it is almost entirely what I would call design.  The function would do the same job without that modifier, but now the signature more eloquently describes its intentions.  So what I’m really saying is that I don’t think design and implementation are separate activities.  This shouldn’t be revolutionary at all, but evidently from what I’m now observing, clearly there are some people who still believe it to be true.  Based on this thinking, I thought I was going to coin a new term: “Continuous Design”, but a quick google showed me there’s already a wikipedia page.  I guess I can’t add myself as a citation now!

Read more of this post

A Team of Champions

Fair warning:  I just read “Quiet: The power of introverts in a world that can’t stop talking” by Susan Cain and this blog post is heavily influenced by that.  She did some spectacular research and presented it in a manner that went down very well with me.  She even used some specific software studies as examples.

One of the rallying cries of a (somewhat) local sports team is “A champion team will always beat a team of champions”.  This clever play on words makes us feel warm inside thinking that if we’re connected to the mass, that all of us is somehow better than each of us.  We are indeed social animals.  The main point of the opening chapters is that actually, studies suggest that while we feel like we do better in a group situation, we actually do better alone.  And more worryingly, that if we’re in a group situation, we don’t just go along with the more vocal person for the social acceptance, believing deep down that we’d chose a different answer if it were up to us, but that the social pressure actually changes our perception entirely.  So I’d like to pick at my previous post a little, with this new information.

Read more of this post