Writing good review comments

The grader rewards the same things a good teammate does.

  • Name the problem, not just the line. "This looks off" scores as partial at best. "Anyone can call this; export_orders has no @staff_member_required" is a full hit.
  • Say what breaks and for whom. "On the last day of the range, orders after midnight are dropped" beats "date filter is wrong".
  • Make it actionable. Suggest the fix or the direction: select_related("customer"), hmac.compare_digest, an AbortController in the effect cleanup.
  • One problem per comment. Two issues in one comment can only match one of them.
  • Comment where the bug lives. Put it on the line that has to change, not the first line of the file.
  • Match severity to impact. See Classifying comments.
  • Don't pad. Ten speculative nitpicks earn little and each false alarm costs points.

A checklist that finds most planted issues:

  1. Auth and permissions on every new entry point.
  2. Input validation and error paths (what returns a 500?).
  3. Queries in loops, unbounded lists, missing indexes.
  4. Concurrency: two requests at once, retries, idempotency.
  5. Async: missing await, effects without cleanup, stale closures.
  6. Data leaks: secrets in client bundles, caches keyed without the user.
  7. Tests for the new behavior.