Skip to main content
US Army Corps of EngineersInstitute for Water Resources, Risk Management Center

Code Review Process

Who Reviews

  • Any Member with Write access: Can review and comment on pull requests
  • Organization Owners: At least one of the 6 owners must approve before merge
  • Self-review: Authors should read the PR before requesting review

Reviewer Responsibilities

What to check:

  1. Correctness: Does the code do what it claims?
  2. Quality: Is it readable, maintainable, and well-structured?
  3. Standards: Does it follow team conventions?
  4. Edge cases: Are errors and edge cases handled?
  5. Security: Are there any security concerns?
  6. Performance: Any obvious performance issues?

Review etiquette:

  • Be kind and constructive
  • Ask questions rather than make demands
  • Explain the "why" behind suggestions
  • Approve if changes are good enough (don't be a perfectionist)
  • Respond within 1 business day if able

Requesting Changes

Use GitHub review features:

  • Comment: Questions or suggestions
  • Request Changes: Issues that must be addressed
  • Approve: Ready to merge

Writing feedback:

  • Be specific: "This function could be simplified" -> "Consider using Array.filter() here to reduce complexity"
  • Acknowledge good work: "Nice error handling here"
  • Distinguish requirements from suggestions: "Must: handle null case" vs "Nit: consider renaming this variable"

Addressing Review Feedback

Author responsibilities:

  1. Read all feedback carefully
  2. Ask questions if feedback is unclear
  3. Make requested changes or discuss alternatives
  4. Respond to all comments (even if just "Fixed" or "Done")
  5. Request re-review after significant changes

Handling disagreements:

  • Discuss in PR comments or Slack/Teams
  • Default to reviewer's suggestion unless there is strong reasoning otherwise
  • Escalate to an Organization Owner if needed
  • Remember: both parties want good code