All Together Now

Reflections on Our First Mob Code Review

Two heads are better than one. Indeed that is commonly the term used to justify various paring and collaboration efforts. Including the deceptively contentious topic of pair and mob programming. Diverse thoughts and opinions can come from individuals from diverse backgrounds, with diverse thoughts and experiences, and at different stages in their career and stage of development.

None of us have three heads, so we rely on collaboration with others to obtain the best solution we can

Part of the Queue

Like many great tales, this story begins a little further back than the actual event. It starts with a queue. A queue of rather large UI code reviews that appeared suddenly a few days before the end of the sprint. Of course one could immediately comment on sudden work bursts, suggesting how work tasks should gradually tick down with developers raising small regular requests to ensure regular integration. I certainly raised that very point rather quickly. However it was the next step which defines the turning point in our story.

Queues may be a part of pandemic life, but regular queues of large pull requests is a warning sign that small regular reviews are not being raised

A Little Less Talk and a Lot More Action

Team dynamics was also an issue. A culture supporting pair programming still doesn’t really exist. This has been partially manufactured through a combination of distributed teams and a lack of dedicated tooling for collaborative programming. The deliver at all costs ethos pushed by the wider group also doesn’t help. However, it’s also due to the preferences of some engineers to work alone and just get stuff done. Not everyone is geared to the pairing style.

Like pairing with humans, rubber duck (or cuddly elephant) programming is not for everyone

Come Together

One morning on our standup the number of open PRs was raised as a blocker. This was my cue to strike. When discussing blockers after updates were finished, I asked how comfortable others were reviewing UI requests. The mixture of silence and mumbled statements of discomfort validated my assumption.

I found the best thing was to try to limit my contributions to questions to ensure others could speak their mind, which is easier said than done

On the Sunny Side of the Street

There were two key benefits that came out of this session. Firstly, discussion on usage of null and undefined enabled us to agree a convention for our team that could be documented in a set of UI review guidelines to help communicate our standard to new joiners, and encourage consistency across our many modules. Rather than it being mandated by myself, using the collective opinions of all to formulate these conventions establishes a shared ownership model that they can continue after my departure.

Learning experiences come from peers at all levels, not just the teacher at the front of the class

Get Yourself Together

If I have inspired you to give a mob review a try, consider the following best practices which worked for me on this occasion:

  1. Consider your tooling carefully. I imagine using collaborative coding tools such as Jetbrains Code With Me orVisual Studio Code Live Share would be great. However, if those are not available a screen share and your existing review tool or IDE will also work well.
  2. Use questions to elicit ideas on what to change rather than imposing your own senior viewpoint. This will better support contribution from colleagues at all levels and facilitate discussion.
  3. Explain the reason for a comment. Explaining why you consider a particular approach to be good or bad helps educate the wider group on your thinking.
  4. Encourage questions. This is a collaborative effort, not a dictation!
  5. Document any agreed guideline conventions that come out of any mob reviews in a shared space. A good example is the Typescript project guidelines which live within the repository.

Lead software engineer with a strong interest in UI, UX, Usability and Agility. Lover of cooking, tea, photography and gin! All views expressed are my own.