Fix plan approval gate and add "Create a plan:" prefix for first message
- Fix build warnings: add #[allow(dead_code)] to unused deserialization fields - Fix plan approval gate bug: block file changes when no plan exists (not just when plan exists but is unapproved) - Add "Create a plan: " prefix to first user message in plan mode - Add prepare_plan_mode_input() helper function for testability - Reset is_first_plan_message flag when entering plan mode via /plan command - Add tests for approval gate (no plan + no changes, no plan + changes) - Add tests for prepare_plan_mode_input (happy, negative, boundary cases)
This commit is contained in:
@@ -716,6 +716,7 @@ impl UiWriter for ConsoleUiWriter {
|
||||
#[derive(serde::Deserialize)]
|
||||
struct PlanCompact {
|
||||
plan_id: String,
|
||||
#[allow(dead_code)]
|
||||
revision: u32,
|
||||
approved_revision: Option<u32>,
|
||||
items: Vec<PlanItemCompact>,
|
||||
@@ -731,6 +732,7 @@ impl UiWriter for ConsoleUiWriter {
|
||||
#[serde(default)]
|
||||
evidence: Vec<String>,
|
||||
#[serde(default)]
|
||||
#[allow(dead_code)]
|
||||
notes: Option<String>,
|
||||
}
|
||||
#[derive(serde::Deserialize)]
|
||||
|
||||
Reference in New Issue
Block a user