Shelves / Senior Engineering Craft
SC·05
Mentoring and Growing Engineers
Why growing other engineers is core senior work: mentoring, coaching, sponsoring and managing compared, how people actually learn skills (deliberate practice, the zone of proximal development, worked examples), onboarding that gets a first change shipped in week one, one-to-ones, teaching through review and pairing, delegating problems instead of solutions, feedback that lands, psychological safety, and spreading knowledge so the team doesn't depend on one person; with a lab that measures knowledge concentration in Flask's source code.
Start here: one author, half the code
Who would understand a codebase if its main author disappeared? The lab ran git blame over the 24 Python files in Flask's src/flask directory (9,566 lines today) and attributed each current line to the author of its last change:
| Contributor (anonymised) | Share of current lines | Cumulative |
|---|---|---|
| #1 | 50.6% | 50.6% |
| #2 | 19.7% | 70.2% |
| #3 | 12.4% | 82.6% |
| #4 | 3.1% | 85.7% |
| #5 | 3.0% | 88.7% |
139 people have authored lines that survive today, yet one person last touched half of them, and in 17 of 24 files one author accounts for more than half the lines (14 of those are the same person). Using a simple definition (remove top authors until more than half the files have lost every author owning at least a quarter of them), the project's truck factor is 1.
Two cautions make this a lesson rather than a verdict. git blame credits whoever touched a line last, so a maintainer who reformats or modernises code "owns" it on paper; and one person can appear under several names. Flask is a healthy, well-documented project with active maintainers. But the same measurement on a company codebase often shows exactly what it suggests: knowledge concentrated in one or two people, who become bottlenecks for reviews, incidents and decisions, and whose departure stalls the team.
Spreading knowledge, teaching skills and growing people into owners is how a senior engineer turns their own expertise into team capacity.
How deep to go
Volume 17 defines six mastery levels. For mentoring:
| Level | What you can do |
|---|---|
| L1 | Help a teammate with a specific problem |
| L2 | Onboard a new engineer; explain your code and decisions clearly |
| L3 | Mentor juniors over months; give useful feedback; delegate with support |
| L4 | Grow engineers to independence and ownership; spread knowledge deliberately; coach rather than solve |
| L5 | Build a team's learning systems: onboarding, rotations, review culture; sponsor people |
| L6 | Develop other senior engineers and leaders across an organisation |
Why this is senior work
A senior engineer who writes excellent code adds one person's output. One who doubles two juniors' effectiveness, and makes the team resilient to absences, adds far more. Organisations' promotion criteria for senior and staff roles reflect this: "raises the bar of the team", "grows others", "force multiplier".
Four related roles:
| Role | What it is | Example |
|---|---|---|
| mentoring | sharing experience, advice and context | "When I've seen this before, the slow part was the N+1 query." |
| coaching | asking questions that help someone think it through | "What would you check first? Why?" |
| sponsoring | spending your credibility to create opportunities | nominating someone to lead a project, crediting them in public |
| managing | formal responsibility for performance, pay and careers | usually an engineering manager's job, not a senior IC's |
Mentoring and coaching are complementary: early in a skill, people need explanations and examples; as they grow, questions build judgment. Sponsorship matters most for advancement, and is the role most often missing for people outside a team's informal networks.
How people learn skills
- Deliberate practice (Anders Ericsson's research on expertise): focused work on specific weaknesses, slightly beyond current ability, with fast feedback and reflection. Routine experience alone plateaus. Design tasks for growth, not just for throughput.
- The zone of proximal development (Lev Vygotsky): the range of tasks someone can't yet do alone but can do with support. Assign work there, with scaffolding (examples, pairing, check-ins) that you remove as they grow.
- Worked examples first, then practice: for novices, studying a complete, well-explained example (a good design doc, a model PR) teaches faster than unguided problem-solving; for more experienced learners, problems work better.
- Retrieval and spacing (Volume 17): explaining from memory and revisiting over time make learning stick. Ask mentees to explain the system back to you.
- Reflection: a short "what went well, what would you change?" after each piece of work converts experience into learning.
Onboarding
A new engineer's first weeks set their trajectory. A plan that works:
| When | Goal |
|---|---|
| day 1 | laptop works; can build, run tests and run the app locally; knows their buddy |
| week 1 | ships a small real change to production, through review, CI and deploy |
| weeks 2–4 | starter tasks of growing size in one area; reads key design docs and ADRs; shadows on-call |
| month 2–3 | owns a small feature end to end; joins on-call with a backup; reviews others' code |
Supporting pieces: an up-to-date setup guide (have each new hire fix what's wrong in it), a curated reading list (architecture overview, recent design docs, ADRs, postmortems; Volume 7), a labelled list of good first tasks, a buddy who isn't their manager, and regular check-ins. Measure "time to first production change" and "time to first on-call shift"; long times reveal friction in the system, not just in the person.
One-to-ones
Regular, short conversations (30 minutes every week or two) with mentees are the backbone of mentoring. The mentee owns the agenda; useful prompts:
- What are you working on, and where are you stuck?
- What did you learn this week? What would you do differently?
- What do you want to get better at in the next three months?
- Is anything getting in your way, at work or in the team?
- What feedback do you have for me?
Take notes, follow up on commitments, and connect conversations over time to their growth goals.
Teaching through everyday work
- Code review (chapter 02): explain why, link to examples, label suggestions vs blockers, ask questions, praise good work. For a new hire's large PR, have a short call: walk through it together and plan a split; the conversation teaches more than 60 comments.
- Pairing: let the less experienced person drive (hold the keyboard) while you navigate; resist taking over. Think aloud when you drive, so they see your process, including dead ends.
- Design reviews: invite juniors to review; ask for their questions first, before seniors speak.
- Incidents (Volume 7): include learners in incident response and postmortems; they show how the system really behaves.
- Your own mistakes: talk openly about them; it signals that learning matters more than looking infallible.
Delegation
Delegating well is how mentees grow into owners, and how you free time for higher-leverage work.
- Delegate problems, not solutions: "Kitchen reports are a day stale; propose how we fix it" rather than "implement Debezium".
- Match the level of support to experience: from "do it with me" through "do it and check with me at these points" to "do it and tell me how it went".
- Agree check-in points and what "done" means up front; make it safe to ask for help early.
- Let them do it differently: if their approach works and isn't risky, accept it, even if you'd have done it another way. Intervene for correctness, safety and real risks.
- Give credit publicly, especially to people whose work is less visible.
The anti-pattern is "it's faster if I do it myself". True this week; false this year.
Feedback
Feedback is information about the effect of someone's behaviour, given so they can choose to change it.
SBI (situation, behaviour, impact; from the Center for Creative Leadership) keeps it concrete:
"In yesterday's design review (situation), you answered the security reviewer's questions with links to the threat model and the specific mitigations (behaviour). It ended the debate in five minutes and got the doc approved (impact)."
"In this PR (situation), the description didn't say how the migration was tested (behaviour). I spent an hour working out whether it was safe to merge (impact). Could you add a testing section next time?"
Principles:
- Timely: within days, not at the half-year review.
- Specific: about a situation and a behaviour, not a trait ("you're careless").
- Private for criticism, public for praise (if the person is comfortable with it).
- Balanced over time: notice and name good work regularly, not only problems; people need to know what to keep doing.
- A conversation: ask for their view; you may be missing context.
- Ask for feedback yourself, and show how you use it.
Psychological safety
Amy Edmondson's research defines psychological safety as a shared belief that the team is safe for interpersonal risk-taking. Google's Project Aristotle study of its teams (reported in 2015–16) found it was the most important of the factors it examined in team effectiveness. In engineering it shows up as people asking "basic" questions, admitting they broke something, reporting near-misses, and disagreeing with seniors in design reviews.
Seniors set the tone: admit what you don't know, thank people for raising problems, run blameless postmortems (Volume 7), respond to mistakes with curiosity ("what made that easy to get wrong?"), and make sure quieter people are heard in meetings. Safety doesn't mean low standards; high standards with high safety is the combination that performs.
Spreading knowledge
The lab's concentration measurement points at a team risk. Ways to raise the bus factor:
- Rotate who works on, reviews and is on call for each service.
- Pair and mob on unfamiliar areas.
- Write things down: architecture overviews, runbooks, ADRs, and recorded walkthroughs of complex code.
- Review across areas deliberately (chapter 02).
- Hold short internal talks ("how the sync engine works in 20 minutes").
- Measure periodically: ownership concentration from git, and "who could fix this at 3 a.m.?" for each service.
Being mentored
Mentoring works both ways. As a mentee (at any level): bring specific questions and context, try first and say what you tried, ask for feedback on one skill at a time, act on advice and report back, and find several mentors for different skills (a staff engineer for architecture, a manager for career, a peer for a technology).
Common traps
- Taking the keyboard or rewriting the mentee's work.
- Giving solutions instead of problems.
- Feedback only at review time, or only negative.
- Hero culture: the senior who fixes everything, and becomes a single point of failure.
- Onboarding by "read the wiki" with no first task.
- Mentoring only people like you; sponsoring no one.
Lab: who knows the code?
Setup. The Flask clone from chapter 02's lab (HEAD at 30 October 2026) and a Python script calling git blame --line-porcelain -w HEAD on each of the 24 .py files in src/flask. Each current line is attributed to the author of the last commit that changed it (ignoring whitespace-only changes). The script reports each author's share of all lines (authors anonymised here), files where one author owns more than half the lines, and a simplified truck factor: authors are removed in order of total share until more than half of the files have lost every "major" author (one owning at least 25% of the file). Published truck-factor algorithms (for example Avelino and colleagues' 2016 method) are more careful; this version shows the idea.
Caveats. Blame credits the last change to each line, so large refactors, reformatting and type-annotation passes shift "ownership" to whoever did them, regardless of who designed the code. Authors with several names or email addresses are counted separately. The result measures where recent line-level changes came from, which is a proxy for knowledge, not knowledge itself.
Results
- 24 files, 9,566 lines, 139 distinct author names.
| Author | Share of current lines | Cumulative |
|---|---|---|
| #1 | 50.6% | 50.6% |
| #2 | 19.7% | 70.2% |
| #3 | 12.4% | 82.6% |
| #4 | 3.1% | 85.7% |
| #5 | 3.0% | 88.7% |
- Files where one author wrote more than 50% of current lines: 17 of 24; in 14 of them it's author #1.
- Simplified truck factor: 1.
What it shows
- Many contributors, concentrated ownership: 139 people contributed, but three account for 83% of current lines.
- Concentration is measurable cheaply, and the measurement starts the right conversation: which areas would be hard to maintain if one person left?
- The proxy needs interpretation: check whether a top "owner" designed the code or reformatted it, and ask the team who actually understands each area.
Try it yourself
- Run the script on your team's main service and list files where one person owns more than 70%.
- Add
--ignore-revs-filewith the hashes of known formatting commits and rerun; how much does ownership change? - Combine with change frequency (
git log --format= --name-only | sort | uniq -c): which files are both frequently changed and concentrated? Start knowledge-sharing there. - For one concentrated area, run a 30-minute recorded walkthrough and pair a second engineer on the next change.
- Repeat the measurement in three months.
Revision sheet: mentoring and growing engineers
Key ideas
- Growing others multiplies a senior engineer's impact; mentoring (advice), coaching (questions), sponsoring (opportunity), managing (formal).
- Learning: deliberate practice, the zone of proximal development with scaffolding, worked examples for novices, retrieval, reflection.
- Onboarding: working setup on day 1, a production change in week 1, growing ownership over 90 days; buddy, reading list, good first tasks.
- One-to-ones owned by the mentee, with follow-up.
- Teach through review, pairing (they drive), design reviews, incidents and your own mistakes.
- Delegate problems with agreed check-ins; accept different approaches; credit publicly.
- Feedback: SBI, timely, specific, private for criticism, balanced, two-way.
- Psychological safety plus high standards; seniors set the tone.
- Raise the bus factor: rotation, pairing, docs, cross-area review, talks, measurement.
Numbers to remember
- Flask
src: top author 50.6% of current lines; 17 of 24 files over 50% one author; simplified truck factor 1.
Glossary
- Sponsorship: using influence to create opportunities for someone.
- Deliberate practice: focused practice on weaknesses with feedback.
- Zone of proximal development: tasks achievable with support.
- Scaffolding: temporary support removed as skill grows.
- SBI: situation, behaviour, impact.
- Psychological safety: belief that it's safe to take interpersonal risks.
- Truck (bus) factor: people who'd have to leave before a project stalls.