Mentoring Go Developers Across Experience Levels
Teaching concurrency, errors, and testing effectively.
Mentoring on Go teams is how idioms outlive any single senior hire.
Structured plans beat ad-hoc advice: juniors need safe baselines, mids need concurrency fluency, seniors need design ownership, and staff candidates need multi-team teaching leverage.
Summary
Effective mentoring matches exercises to leveling expectations.
Juniors practice gofmt, table tests, and explicit error returns.
Mid-level engineers pair on context, channels, and interface boundaries.
Seniors co-own design reviews and ADR drafts.
Staff-track engineers demonstrate cross-package patterns through reference PRs and review calibration.
Every level benefits from artifacts - merged PRs, test files, doc notes - not verbal promises to improve.
Recipe
Quick-reference recipe card - copy-paste ready.
## Mentoring plan - <name> - <level>
Quarter goal:
Week 1-4: <skill> -> artifact PR
Week 5-8: <skill> -> artifact PR
Review themes to watch: errors, concurrency, API exports
Buddy rotation: <engineer> by week 6When to reach for this:
- New hire ramp after onboarding checklist
- Promotion calibration quarter
- Repeated review themes on one engineer
- Preparing a senior for tech lead or staff scope
- Recovering confidence after a production incident involving their code
Working Example
Mentor guides a mid-level engineer through concurrency in a real queue consumer.
func TestWorkerRespectsCancel(t *testing.T) {
ctx, cancel := context.WithCancel(context.Background())
defer cancel()
w := NewWorker(fakeSender{delay: 50 * time.Millisecond})
done := make(chan error, 1)
go func() { done <- w.Run(ctx) }()
time.Sleep(10 * time.Millisecond)
cancel()
select {
case err := <-done:
if !errors.Is(err, context.Canceled) {
t.Fatalf("got %v want cancel", err)
}
case <-time.After(time.Second):
t.Fatal("worker did not stop")
}
}// Mentor asks author to add -race in CI job comment on PR
// go test -race ./internal/worker/...What this demonstrates:
- Tests prove shutdown behavior, not only happy path
contextcancellation is verifiable in unit tests- Mentor ties exercise to production incident class (stuck workers)
- Race detector becomes a habit before merge
Deep Dive
How It Works
- Mentor and mentee agree on one measurable quarterly outcome (for example, "own concurrency PRs without rework").
- Weekly 30-minute sessions follow an agenda: review last PR, teach one concept, assign micro-PR homework.
- Buddies rotate monthly so mentees hear multiple review voices.
- Progress evidence lives in tickets: links to PRs, test files, design comments.
Level-Specific Focus
| Level | Emphasis | Sample artifact |
|---|---|---|
| Junior | Toolchain, table tests, error returns | Docs+test first PR |
| Mid | context, interfaces at consumer, -race | Worker or handler PR |
| Senior | Design input, ADR draft, review teaching | RFC comments + ADR |
| Staff track | Cross-team library, review calibration | Shared middleware PR |
Go Notes
// Error lab: mentee refactors to %w and adds errors.Is test
var ErrNotFound = errors.New("not found")
func TestIsNotFound(t *testing.T) {
err := fmt.Errorf("load: %w", ErrNotFound)
if !errors.Is(err, ErrNotFound) {
t.Fatal("expected ErrNotFound in chain")
}
}- Teach wrapping at the layer that adds context, not every log site.
- Interfaces defined by consumers: exercise with
io.Readerstyle examples from their codebase. - Generics: show when type parameters clarify APIs vs unnecessary abstraction.
Teaching Concurrency Safely
- Start with sequential code correct under errors before introducing goroutines.
- Introduce
errgroupbefore raw channel orchestration for most service code. - Require
go test -raceon packages touched; explain a past race found in prod if available. - Never assign on-call primary for untested concurrent paths.
Gotchas
- Lecture-only mentoring - Fix: Every session ends with a PR or ticket update due within one week.
- Same buddy forever - Fix: Rotate after 4-6 weeks to expose review diversity.
- Skipping juniors on design - Fix: Invite observers to design reviews early; assign comment homework.
- Teaching frameworks before stdlib - Fix: Anchor on
net/http,context, andtestingbefore chi/gin exceptions. - Vague "be more senior" feedback - Fix: Map to leveling guide bullets with evidence checklist.
- Mentor unavailable during crunch - Fix: Protect calendar blocks; crunch without mentoring burns future velocity.
Alternatives
| Alternative | Use When | Don't Use When |
|---|---|---|
| Mob programming | Complex concurrency change | Mentee needs solo ownership practice |
| External workshop | Team-wide Effective Go refresh | Individual gap on your codebase |
| Self-serve reading path | Hire is self-directed | Concurrency/errors need live feedback |
| Formal training budget | Company offers Go courses | No follow-up PR application |
FAQs
How much time should tech leads spend mentoring?
Roughly 2-4 hours per week across plans and pairing; scale down feature ownership accordingly.
What if the mentee resists pairing?
Tie pairing to concrete PR deadlines and leveling evidence; escalate to manager if avoidance persists.
How do I mentor someone more experienced in Go than me?
Focus on org context: ADRs, deploy constraints, on-call patterns - learn from their idioms while supplying system knowledge.
Should mentors approve their mentee's PRs?
Sometimes for teaching, but rotate approvers so review bar reflects team norms not one voice.
How handle repeated concurrency mistakes?
Shrink scope to a library-sized exercise, require -race green, and second reviewer on next three concurrent PRs.
Are 1:1s the same as mentoring sessions?
No. Manager 1:1s cover career and feedback; mentoring sessions are technical with agendas and artifacts.
How document mentoring outcomes?
Quarterly note: PR links, skills demonstrated, gaps for next quarter - feeds promotion packets.
Can juniors mentor?
Yes on docs, tests, and tooling they mastered - strengthens teaching skill without owning concurrency review.
What books supplement mentoring?
Effective Go and your internal ADR index beat random blogs; assign reading blocks with exercise PRs.
How mentor across time zones?
Async review comments plus recorded pairing summaries; keep overlapping live hour for complex topics.
When escalate mentoring to performance plan?
When agreed artifacts miss deadlines repeatedly after scope adjustment - involve manager with evidence.
How staff engineers mentor tech leads?
Model cross-team RFCs, calibrate review tone, and co-facilitate disagreement sessions.
Related
- Technical Leadership in Go Teams - growth loop in leadership model
- Tech Leadership Basics - mentoring block scheduling example
- Onboarding Go Specialists - ramp from other languages
- Code Review Culture for Go - teaching through PRs
- Leveling Guide: Junior to Staff in Go - expectations by band
- Pairing & Mob Sessions for Go Teams - live teaching formats
Stack versions: This page was written for Go 1.26.x (Green Tea GC default, go fix modernizers - verify patch at build), chi (latest - verify at build), gin (latest - verify at build), echo (latest - verify at build), google.golang.org/grpc (latest - verify at build), sigs.k8s.io/controller-runtime (latest - verify at build), kubebuilder (latest - verify at build), tinygo (latest - verify board targets at build), wazero (latest - verify at build), and golangci-lint (latest - verify linter set at build).