Part of the tech lead role is to be available for help. Setting up office hours and pair programming is vital to avoid the mental load of task switching.
With everything a tech lead has on his plate, finding quality time to help your teammates is tricky! You know the story:
Every time someone comes for help with a problem, I suffer mental task switching to dive in his work!
It’s difficult to find the mental availability required to give good code reviews!
How am I going to finish this feature when I am interrupted all the time?
If this resonates with you, here are a few tips that will help you!
Task switching is driving us mad!
I remember my first time as a tech lead. Out of habit, I continued to work on the challenging features I used to. The glitch was that now everyone in my team was coming at me with their problems! It quickly resulted in:
- Useless task switching
- Stressful mental load
- Painful long hours
- And late deliveries
Some of the primary responsibilities of a tech lead are about assisting your team:
- Review teammates’ code
- Discuss design with them
- And help them to remove a blockage
There is no way you can escape this part of the job.
It took me a while to find a way around this challenge. As we’ll see later, eXtreme Programming made the problem a lot simpler. But I also needed to learn my first lesson as a new tech lead: the fundamental difference in schedules.
Manager’s vs. Maker’s Schedule
Programmers need long slots of uninterrupted time to focus on deep work. Managers need to jump from one meeting to another. The later cope with this task-switching because they don’t need to go deep on any topic.
These different schedules are a particular challenge for Tech Leads, who need to do both! As Jayesh Lalwani wrote on Quora:
A Tech Lead is by definition, someone who is too good to be “just” a programmer […] Once, you get there, you are parked in this halfway house of being part manager who isn’t management, and part architect who isn’t the architect.
As a tech lead, you need to find time for both Manager and Maker schedules.
Office hours to the Rescue
Office Hours definition, according to Wiktionary:
A pre-arranged time when a person whose occupation frequently takes them away from their office during working hours is available in their office to answer questions or provide assistance without the requirement for an appointment.
Setting up office hours to help your teammates is the most effective way to reduce task switching.
A drawing is worth a thousand words. Here is why office hours are important. Without office hours, your day will likely look like that:
After you have set up office hours, it should look something like this:
Booking office hours in your calendar will have 2 effects:
- It will contain interruptions within a predefined time slot
- It will also group other meetings during the rest of the day. Once you have blocked out a time-slot in your calendar, people won’t set you meetings there!
The main benefit for you is a massive reduction in task switching. At the end of the day, this means less mental load and calmer work!
Max out office hours with pair programming
Office hours work great. Here’s a slight twist to make them even more useful for you and for your team. When someone comes at you for help, default to pair programming.
Why should you favor pair programming over other kinds of help?
- It’s the most effective way to up-skill your teammates. If you want to read more, here is what happened in a previous team where we introduced pair programming.
- It transforms after-the-fact reviews and validation into synchronous collaboration.
- These 2 combined make it the fastest way to build an autonomous team.
I hate doing code review. I love pairing.— Jessica Joy Kerr (@jessitron) August 25, 2016
I don't want to exert judgement on your code, I want to collaborate on code.
Pairing is a long term investment. In the long run, it will make you dispensable and create more time for your deep work!
In practice, it’s straightforward:
- Stop answering questions or doing asynchronous code reviews
- Start moving to their desks, or asking them to share their screens
As developers, we refactor code to make it easier to work with. Introducing some pair programming is a first step to refactor how your team works. With time, both kinds of refactoring compound and create an environment for calm work.
Set pairing office hours now!
Here is the 5-minutes fix you should do now to stop this task switching that is making you crazy.
How to setup office hours:
- Book a slot in your calendar: 1 or 2 hours, every day, at the same time.
- Invite your team as optional participants.
- Present your initiative to your teammates. Share your pains and ask for feedback. Use the medium that makes the most sense to you and your team: email, chat, meeting, or anything else.
- Have some work ready in case no one needs you. Reviewing code is fine, but you can also use this time to work on tasks that have low priority and don’t need a deep focus.
- Regularly ask for feedback from your team to know how it is working for them. If you have retrospectives in place, this can be the perfect time for this. Otherwise, just make sure to get regular feedback!
- Use your team’s feedback to iterate and fine-tune the best formula for you and your team.
You could go even further by blocking maker hours, as out of office, in your calendar! That’s a bolder move, though, and a good topic for a follow-up post. Stay tuned!
I’d really love to know how you deal with the tech lead’s task switching. Don’t hesitate to share anything through the comments.