Code review and safe recovery
Use this lesson to build a practical, evidence-based Nova workflow for this topic.Review is an evidence task
A useful code review identifies defects that can be demonstrated from the code, diff, tests, or runtime behaviour. It should prioritise findings by impact and avoid filling the response with stylistic preferences. Nova can review:- Uncommitted working-tree changes.
- Staged changes.
- A specific commit or range.
- A pull-request diff supplied through an available integration.
- Selected files or a subsystem.
- Security-sensitive code from a defensive perspective.
/review command. Ask Nova directly, invoke a review-oriented skill if installed, or create a project slash command under .compass/commands for a repeatable team workflow.
A strong review request
Define both scope and review priorities:Review workflow
Nova should normally:- Inspect repository status to understand staged, unstaged, and untracked files.
- Read a summary before requesting a large diff.
- Examine changed files with enough surrounding context.
- Trace affected call sites, contracts, and tests.
- Run focused, non-destructive checks where they improve confidence.
- Report findings before summaries or compliments.
- Severity or practical impact.
- The exact path and line.
- Why the current behaviour is wrong.
- A realistic trigger or failure scenario.
- The smallest credible remediation.
Use the verification agent for independent checks
Nova includes a specialised verification profile for read-only review, security inspection, reproducing failures, and targeted test validation. It is useful when an implementation agent has already changed the code and an isolated second pass would reduce confirmation bias. The verification result should provide aPASS, FAIL, PARTIAL, or BLOCKED verdict with concrete evidence. The parent session must still assess the findings before acting on them.
Diff discipline
A review should separate:- Changes introduced by the current task.
- Pre-existing user changes.
- Generated output.
- Untracked files that may contain secrets or local state.
Conversation rollback
Nova supports:Checkpoint file restoration
Where workflow checkpoints are enabled, Nova can preview a file-scoped recovery plan:Git-based recovery
Git provides the strongest audit trail for committed and staged work, but recovery commands vary in destructiveness. Before reverting anything:- Inspect status and the relevant diff.
- Identify uncommitted work that must be preserved.
- Prefer a new revert commit for shared history.
- Avoid force pushes and history rewriting unless explicitly authorised and safe.
- Never use a destructive reset as a shortcut around understanding the change.