From wrangler
Conducts systematic code review with quality checks, architectural verification, and actionable feedback. Use when reviewing pull requests, code changes, or ensuring code quality standards.
npx claudepluginhub bacchus-labs/wrangler --plugin wranglerThis skill uses the workspace's default tool permissions.
- **Plan alignment first** - Implementation must match stated requirements
Guides strict Test-Driven Development (TDD): write failing tests first for features, bugfixes, refactors before any production code. Enforces red-green-refactor cycle.
Guides systematic root cause investigation for bugs, test failures, unexpected behavior, performance issues, and build failures before proposing fixes.
Guides A/B test setup with mandatory gates for hypothesis validation, metrics definition, sample size calculation, and execution readiness checks.
Purpose: Verify implementation matches original requirements.
Process:
Evaluate:
Output: List of alignment issues with severity
Purpose: Ensure code meets quality standards.
Review Areas:
any types without justificationOutput: Quality issues categorized by area
Purpose: Validate architectural soundness.
Evaluate:
Output: Architectural concerns with recommendations
Purpose: Ensure adequate test coverage, quality, and TDD compliance.
Verify tests were written BEFORE implementation:
Questions to ask:
Does each function/method have corresponding tests?
For each public function in implementation files:
- [ ] Test file exists
- [ ] Test covers function behavior
- [ ] Test name clearly describes what's tested
If NO: Flag as Important issue
IMPORTANT: Missing tests for [function_name] in [file].
All functions require tests. Add tests before merging.
Request TDD Compliance Certification
Ask implementer to provide certification from practicing-tdd skill:
"Please provide TDD Compliance Certification for each function (format from practicing-tdd skill)."
Verify:
If certification missing or incomplete: Flag as Important issue
IMPORTANT: TDD Compliance Certification required.
Must provide certification with one entry per function (see practicing-tdd skill).
Certification proves RED-GREEN-REFACTOR cycle was followed.
If author cannot provide certification: Flag as Important issue
IMPORTANT: Unable to verify TDD followed for [function_name].
Tests may have been written after implementation.
Recommend: Verify tests actually fail when implementation removed.
Do tests fail when implementation removed?
If suspicious that tests written after (e.g., all tests pass immediately, no git history showing test-first):
# Verify tests actually test implementation
# Comment out implementation
git stash # Temporarily remove implementation
npm test # Tests should FAIL
git stash pop # Restore implementation
If tests still pass with no implementation: Flag as Critical issue
CRITICAL: Tests for [function_name] pass without implementation.
Tests are not actually testing the code.
See avoiding-testing-anti-patterns skill (Anti-Pattern 1: Testing Mock Behavior).
Rewrite tests to verify real behavior.
Does git history suggest test-first?
Optional check (not definitive, but helpful indicator):
git log --oneline --all -- tests/[file].test.ts src/[file].ts
Look for:
If commits show implementation before tests: Flag as Important issue
IMPORTANT: Git history suggests tests written after implementation.
Commits show [file].ts before [file].test.ts.
Verify TDD was followed. If not, recommend rewriting with TDD.
Are there any files with implementation but no tests?
# Find source files
find src/ -name "*.ts" -o -name "*.js"
# For each source file, check if test exists
# tests/[name].test.ts or tests/[name].spec.ts
If source file has no corresponding test file: Flag as Important issue
IMPORTANT: No tests found for src/[file].ts
All implementation files require tests.
Add comprehensive tests before merging.
TDD Compliance Summary:
After checking above:
### TDD Compliance: [PASS / NEEDS IMPROVEMENT / FAIL]
- Functions with tests: X / Y (Z% coverage)
- Author attestation to RED-GREEN-REFACTOR: [Yes / No / Partial]
- Tests verified to fail without implementation: [Yes / No / Not checked]
- Files without tests: [List or "None"]
[If NEEDS IMPROVEMENT or FAIL]:
Recommendations:
- Add tests for [list functions]
- Verify tests for [list functions] actually fail when implementation removed
- Consider rewriting [list functions] with TDD for higher confidence
See Also: avoiding-testing-anti-patterns skill for what NOT to do, practicing-tdd skill for TDD process
Output: Testing gaps, quality issues, and TDD compliance status
Purpose: Identify vulnerabilities and performance issues.
Security Review:
Performance Review:
Output: Security and performance concerns
Purpose: Verify code is properly documented.
Check:
Output: Documentation gaps
Categorize all findings by Priority:
Structure your review as follows:
# Code Review: [What Was Implemented]
## Summary
**Overall Assessment**: [Ready to merge / Needs fixes / Major revision needed]
**Strengths**:
- [What was done well]
- [Good decisions made]
- [Quality aspects worth noting]
**Issues Found**: [X] Critical, [Y] Important, [Z] Minor
---
## Critical Issues
### 1. [Issue Title]
**Location**: `file/path.ts:123-145`
**Issue**: [Specific problem with evidence]
**Impact**: [Why this is critical]
**Fix**: [Specific steps to resolve]
---
## Important Issues
### 1. [Issue Title]
**Location**: `file/path.ts:67`
**Issue**: [Specific problem]
**Why Important**: [Consequences if not fixed]
**Recommendation**: [How to fix]
---
## Minor Issues
### 1. [Issue Title]
**Location**: `file/path.ts:89`
**Suggestion**: [Improvement idea]
**Benefit**: [Why this would help]
---
## Plan Alignment
**Planned**: [What the plan said to do]
**Implemented**: [What was actually done]
**Deviations**:
- [Deviation 1]: [Justified/Problematic and why]
- [Deviation 2]: [Assessment]
---
## Testing Review
### TDD Compliance: [PASS / NEEDS IMPROVEMENT / FAIL]
**Findings:**
- Functions with tests: X / Y (Z% coverage)
- Author attestation to TDD: [Yes / No / Partial]
- Tests verified to fail without implementation: [Yes / No / Not checked]
- Files without tests: [List or "None"]
**Issues identified:**
[List TDD compliance issues here]
### Test Coverage
**Coverage**: [Percentage or qualitative assessment]
**Gaps**:
- [Untested scenario 1]
- [Untested scenario 2]
**Test Quality**: [Assessment]
---
## Recommendations
**Immediate Actions** (before merge):
1. [Action 1]
2. [Action 2]
**Future Improvements** (can defer):
1. [Improvement 1]
2. [Improvement 2]
---
## Approval Status
- [ ] Critical issues resolved
- [ ] Important issues addressed or acknowledged
- [ ] Tests passing
- [ ] Documentation updated
**Status**: [Approved / Approved with minor items / Needs revision]
See requesting-reviewing-code skill for how to invoke this review process.
When to review:
See receiving-reviewing-code skill for how to handle review feedback.
Key principles:
Copy this checklist to track your progress:
See assets/workflow-checklist.md for the complete checklist.
For detailed information, see:
references/detailed-guide.md - Complete workflow details, examples, and troubleshooting