Module 5: Applied Design & Code Review: Mistake Clinic
This clinic turns wrong moves into reusable judgment. Use it after each practice page and again before the quiz or checkpoint.
Module-Specific Mistake Radar
Start with these traps. Replace or extend them with real mistakes from your own work.
| Mistake to look for | Where it shows up | Symptom | Repair evidence |
|---|---|---|---|
| Finishing Pattern Integration Lab with only a final answer | Pattern Integration Lab | The work has no failed case, trace, test, proof gap, or design stress point. | Add the smallest broken example and show the repair that changes the result. |
| Finishing Code Review Workshop with only a final answer | Code Review Workshop | The work has no failed case, trace, test, proof gap, or design stress point. | Add the smallest broken example and show the repair that changes the result. |
| Finishing Design Documentation Clinic with only a final answer | Design Documentation Clinic | The work has no failed case, trace, test, proof gap, or design stress point. | Add the smallest broken example and show the repair that changes the result. |
| Finishing Code Katas with only a final answer | Code Katas | The work has no failed case, trace, test, proof gap, or design stress point. | Add the smallest broken example and show the repair that changes the result. |
| Treating Choosing Patterns as a Response to Design Pressure as vocabulary instead of a tool | Choosing Patterns as a Response to Design Pressure | The explanation names the concept but cannot decide between two cases. | Write one example, one non-example, and the rule that separates them. |
| Treating Combining Patterns: Decorator + Strategy + Factory in One Feature as vocabulary instead of a tool | Combining Patterns: Decorator + Strategy + Factory in One Feature | The explanation names the concept but cannot decide between two cases. | Write one example, one non-example, and the rule that separates them. |
Practice Mistake Checks
Pull any miss from these checks into your mistake log.
Pattern Integration Lab
Source: practice/01-pattern-integration-lab.md
Identify the error in each:
- "I added a
DiscountStrategyinterface even though there is only one discount type today, because you might add more later." - "Logging is hand-written in each of the three strategies; the code is identical, but it's faster to copy."
- "The factory does a
switchon storefront insidePricingEngine.price()instead of in a dedicated class." - "The caching decorator has its own copy of
compute_totalrather than delegating to the inner strategy."
Design Documentation Clinic
Source: practice/03-design-documentation-clinic.md
Identify the error in each:
- An ADR with a "Context" section that reads like a sales pitch for the chosen option.
- A design doc with no "Non-Goals" section.
- A sequence diagram showing only the happy path.
- A design doc and an ADR that disagree about the same decision.
- "Alternatives Considered: None." (in an ADR where there are obviously multiple options)