From code-review
Code review guidance based on Armin Ronacher's pragmatic philosophy. Use for reviewing web frameworks, libraries, API design, error handling, and dependency management. Emphasizes context-appropriate design (product vs library), minimal dependencies, backward compatibility, and solving real user problems over theoretical elegance.
How this skill is triggered — by the user, by Claude, or both
Slash command
/code-review:code-review-mitsuhikoThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
Apply mitsuhiko's practical engineering principles to build sustainable software that solves real problems.
Apply mitsuhiko's practical engineering principles to build sustainable software that solves real problems.
Context-appropriate design: Different projects need different approaches. Products optimize for speed and user value; libraries optimize for stability and reusability.
Simplest working solution: "Do the dumbest thing that works" - pragmatic choices beat theoretical perfection when validating ideas.
User problems over internal elegance: Users don't see your beautiful architecture. They care whether the software solves their problem.
Stability is a feature: Backward compatibility and reliability trump new features. Breaking changes have permanent cost.
Priority: Ship fast, solve user problems, iterate based on feedback.
Review questions:
Good patterns:
Red flags:
Example: The Flamework philosophy - deliberately choose simple, even "ugly" solutions to ship and learn fast. Refactor when proven valuable.
Priority: Long-term stability, clear APIs, extensibility, backward compatibility.
Review questions:
Good patterns:
Red flags:
Compatibility pledge: "I'd rather skip a feature than break existing code." Stability builds trust and ecosystem.
The dependency treadmill: Each dependency brings transitive deps, security risks, and endless upgrade churn.
Review questions:
When to build yourself:
When to use dependencies:
Red flags:
Goal: Zero or minimal dependencies. Code that runs unchanged for years without upgrade pressure.
The string error trap: Jamming error info into strings forces parsing later and breaks programmatic handling.
Principle: "Design error types with as much care as return values."
Review questions:
Good patterns:
Red flags:
throw Error("Invalid user") without contextExample: Instead of ValueError("42 is invalid"), use ValidationError(field="age", value=42, constraint="must be 18-120", context={...}).
Inspired by Trac: Design for extensibility from day one through hooks, plugins, and clear interfaces.
Review questions:
Good patterns:
Red flags:
Progressive typing: TypeScript proved gradual types work. Types help humans AND machines.
Review questions:
Good patterns:
Language preferences:
Avoid: Over-clever type gymnastics that confuse more than help. Types serve understanding.
Principle: "I'd rather not add a feature than break existing code."
Compatibility checklist:
Breaking changes:
Red flags:
Does this solve a real problem users have, or just satisfy our aesthetic preferences?
Will maintaining this for 5 years cost more than the value it provides?
For each new dependency: Can we build it in <50 lines? Is the maintenance burden worth it?
Can production errors be diagnosed from the error alone, or do you need to read code?
If a user needs slightly different behavior, can they extend it or must they fork?
Context assessment:
Code quality:
API design (for libraries):
Instead of: "This is too complex" Say: "For a product feature, consider simpler approach: [sketch]. Ship fast, validate, refactor if proven valuable."
Instead of: "Add this dependency" Say: "This dependency adds N transitive deps for X functionality. We can implement in ~Y lines: [sketch]. Ownership benefits: [list]."
Instead of: "Just throw an error"
Say: "Let's design error type: class FooError with fields [x, y, z]. Benefits: programmatic handling, better debugging, i18n-ready."
Instead of: "Breaking change needed" Say: "Deprecation path: Step 1 (warnings), Step 2 (wait one major version), Step 3 (remove). Migration guide: [outline]."
Python: Rich stdlib, type hints for clarity, avoid over-abstraction, Flask-style simplicity
JavaScript/TypeScript: Use TS for maintainability, but avoid type complexity. Watch npm dependency explosion.
Rust: Acceptable complexity for safety/performance. Still audit dependency trees. Zero-cost abstractions encouraged.
Go: Simple, explicit, great for AI-assisted development. Limited magic by design.
"When building an application, reusability isn't that important. When building a library, it's crucial."
"Perfect code doesn't guarantee success if it doesn't solve real user problems."
"A little code duplication is better than a little dependency."
"Backward compatibility is a feature, not a constraint."
"Design your errors as carefully as your return values."
Remember: The goal is sustainable software that solves real problems. Pragmatism and stability beat theoretical purity.
npx claudepluginhub wilbeibi/claude-toolkit --plugin code-reviewGuides design, architecture, and review of production-grade Python libraries: structure, API design, testing strategy, and implementation trade-offs.
Reviews Ruby, Rails, and JavaScript code in DHH style for convention violations, JavaScript framework contamination, and unnecessary complexity.
Provides checklists for code reviews assessing correctness, security vulnerabilities, performance, and maintainability. Use for pull requests, audits, and feedback.