Loading...
Loading...
MCP-powered multi-dimensional code review for .NET projects. Uses Roslyn analysis tools for antipatterns, diagnostics, references, and dependency graphs combined with structured manual review. Prioritizes effort with blast-radius scoring — data access, security, concurrency, and integration boundaries before style — and produces severity-categorized findings with actionable fixes. Use when: "review", "code review", "PR review", "review this", "review my code", "check code quality", "review changes", "what should I review", "review priorities", "blast radius", "critical path".
npx skill4agent add codewithmukesh/dotnet-claude-kit code-reviewgit diff main...HEAD| Blast Radius | Examples | Depth |
|---|---|---|
| Critical | Middleware, auth, DB migrations, shared kernel, CI/CD | Thorough — every code path |
| High | Public API changes, message consumers, EF configuration, new module | Focused — consumers + behavior |
| Medium | New feature following existing patterns, bug fix, new endpoint | Standard — checklist pass |
| Low | Docs, formatting, renames, logging statements | Glance — build + tests pass |
detect_antipatterns(projectFilter: "affected-project") → async void, DateTime.Now, new HttpClient(), broad catch
get_diagnostics(scope: "project", path: "affected-project") → new warnings, nullability issuesfind_references(symbolName: "ModifiedType") → count consumers; high count = high risk
get_dependency_graph(symbolName: "ModifiedMethod", depth: 2) → ripple effectsget_project_graphdetect_circular_dependenciesfind_references| Priority | Area | Check |
|---|---|---|
| 1 | Data access | N+1 (missing |
| 2 | Security | Every endpoint has explicit |
| 3 | Concurrency | Token propagated end-to-end, no |
| 4 | Integration | Retry/timeout on external calls, consumer idempotency, no swallowed exceptions |
| 5 | Correctness | Business logic, edge cases (empty/null/concurrent), entities mapped to DTOs at the boundary |
| 6 | Tests | Behavior tested (not implementation); happy path + main error case covered |
| — | Style/naming | Mention only after the above; formatters and analyzers own this |
## Code Review: [Scope]
### Summary
[1-3 sentences: scope, risk level, recommendation]
### Critical (must fix before merge)
- **[Title]** — [file:line] [What's wrong. Why it matters. How to fix.]
### Warnings (should fix, creates tech debt)
- **[Title]** — [file:line] [...]
### Suggestions (nice to have)
- **[Title]** — [file:line] [...]
### Architecture Compliance
[PASS/WARN with boundary-violation notes]
### Test Coverage
[Which changed types have tests; specific scenarios to add]
### What's Good
- [Always include — reinforce good patterns]detect_antipatternsget_diagnosticsUser: /code-review the changes in this PR
Claude: 7 changed files across 3 projects. CreateOrder touches data access
and a public endpoint — High blast radius. Running MCP analysis...
## Code Review: Order Processing Feature
### Summary
Adds CreateOrder/GetOrder endpoints with EF Core persistence. Well-structured
VSA feature. Two issues need attention before merge.
### Critical (must fix before merge)
- **Missing CancellationToken propagation** — CreateOrder.cs:38
SaveChangesAsync() called without the token. Client disconnects keep
burning server resources. Pass `ct` from the handler parameter.
### Warnings (should fix, creates tech debt)
- **N+1 query in GetOrder** — GetOrder.cs:25
Order loaded without `.Include(o => o.Items)`; one lazy load per item
during serialization. Eager-load or use a projection.
### Suggestions (nice to have)
- **Seal the handler** — CreateOrderHandler.cs:10
Not designed for inheritance; `sealed` enables devirtualization.
### Architecture Compliance
PASS — all changes within Features/Orders/, no layer violations.
### Test Coverage
Happy path covered. Add tests for validation failure and not-found.
### What's Good
- Clean command/query separation; FluentValidation covers edge cases
- Response DTOs are records, no entity leaks/de-sloppify/verify/health-check