Ruby

http://s.erious.ly

Author Archive

Ensure With Explicit Return

Quick! What does the following method do when thing.method_that_might_raise! raises SomeAppException? And why is this a code smell?

1 def some_method
2   thing.method_that_might_raise!
3   ensure
4     return thing
5 end

Before giving the answers to these two questions,...

Pairing With Hitch

Pair programming does present some unique problems, one that we encountered at Hashrocket was commit attribution: a commit message would be identified with one member of the pair only. This is not exactly tragic, but from the perspective of a passioniate developer, having commit credit (and accountability) is a critical and visible part...

Most Bugs Fall to the Second Pair of Eyes

While recently discussing if a power law applies to bugs at the ongoing seminar I sentimentally call work, I noted a corollary to Linus’s Law.

Linus’s Law states:

Given enough eyeballs, all bugs are shallow

The corollary is:

Most bugs fall to the second pair of eyes

That is, just having one other developer look at a bug will...

Velocity Is Not Destiny

One of the most persistent and pernicious stumbling blocks I see when a team is starting out with Agile1 is equating story points and velocity directly with hours.

Often this stumbling block is not apparent immediately; it often crops up after a few iterations have passed. As an example, a stakeholder who was...