Repository navigation
Separate plan-review verdict policy from application confirmation - #193
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 94cd67566d
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| .get("rebase_mode", "") or "") | ||
| if not mode: | ||
| return "" | ||
| from ..engine.executor import _eval_when |
There was a problem hiding this comment.
Keep the review leaf independent of the engine
When a mode-aware plan is reviewed, this new review/ leaf imports engine.executor, violating the explicit dependency rule in doc/architecture/SPEC/_ARCHITECTURE.md:66-67 that review/ must never import engine/. This also creates a bidirectional package dependency because engine code such as engine/steps/workspace.py:8 already imports from review/, undermining the boundary this refactor introduces; move the mode-context assembly back to an orchestration layer or inject the condition evaluator instead.
Useful? React with 👍 / 👎.
Plan-review context, reviewer verdict interpretation, and interactive confirmation lived together in
app.core. Move mode-aware context and verdict policy intoreview.plan_gate, which returns a typed decision and notices.app.corestill supplies the reviewer, renders notices, and owns human confirmation and run orchestration. The existingCopilot._plan_review_gateand_mode_review_contextimport paths remain compatible.This preserves the unattended fail-closed rule:
blockalways stops, whilereviseandunavailablestop--yesruns and are surfaced for interactive confirmation. No playbook execution, checkpoint, or run-status behavior changes. Validation: 45 focused gate/mode tests and 1,528 full tests passed; strict SPEC freshness andgit diff --checkpassed. The full suite emitted one pre-existing Pydantic forward-reference warning.