Code Review Skill
When reviewing code, follow these comprehensive guidelines to provide thorough, constructive, and actionable feedback.
Review Process
Understand the Context
- Read the PR description and linked issues
- Understand the purpose of the changes
- Review the overall architecture impact
Check for Correctness
- Verify logic is correct
- Look for edge cases
- Check error handling
- Ensure thread safety if applicable
Evaluate Code Quality
- Assess readability and clarity
- Check naming conventions
- Review code organization
- Look for code duplication
Security Review
- Check for injection vulnerabilities
- Verify authentication/authorization
- Look for sensitive data exposure
- Review input validation
Performance Considerations
- Identify potential bottlenecks
- Check for unnecessary allocations
- Review database queries
- Consider caching opportunities
Feedback Guidelines
- Be specific and actionable
- Explain the "why" behind suggestions
- Provide code examples when helpful
- Distinguish between blocking issues and suggestions
- Acknowledge good practices