Stok Footage

Continually experimenting with new ideas and techniques — Reconstructing, Developing, Modernising.

First Lessons From “Rite of Spring” Exercise

Starting to work through Sandi Metz’s RailsConf slides has been an enjoyable and relaxing exercise. I have made it through the first hundred or so slides, and I consciously observed my behaviour. Domestic constraints meant that I needed to wrap up for the day around slide 99 and quickly implement conjured_trick for a sense of closure.

The observation of my progress through the slides, and disciplining myself to make each commit focussed was a revelation. Many years of “fire-fighting” coding, and environments where code quality can happen “later” have ingrained in me urges to speed toward completion. Code katas and pair programming both help to counteract those urges — my observations are probably not news to people who care about their craft. I never cease to be amazed by how refreshing I find these exercises to be.

The most obvious area for improvement is my urge to rewrite new code and delete old code while I’m making an initial change. Working through the slides made me concentrate on following the red / green / refactor discipline, and catch myself as I rushed to squeeze little refactorings into the red part of the cycle. A contributing factor is the urge to see things improve all the time, and slide 97 (below) makes it obvious that things can be messy while you’re tidying up.

All the expected lessons were there, the tests are a safety net, and working in small steps means I’m never that far away from working code. An unexpected lesson was that the added focus has made me wonder if there are some tests missing… That’s for another post.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.