From 4de5b25c52e196c71738df642a5fb84797ed606b Mon Sep 17 00:00:00 2001 From: jif-oai Date: Tue, 14 Oct 2025 13:45:23 +0100 Subject: [PATCH] V15 --- codex-rs/cli/src/infty/commands.rs | 18 ++++++------- codex-rs/cli/src/infty/progress.rs | 32 ++++++++++++------------ codex-rs/cli/src/infty/summary.rs | 18 +++++-------- codex-rs/codex-infty/src/orchestrator.rs | 22 +++++----------- 4 files changed, 37 insertions(+), 53 deletions(-) diff --git a/codex-rs/cli/src/infty/commands.rs b/codex-rs/cli/src/infty/commands.rs index 09376bbd0a..5cab37f9c6 100644 --- a/codex-rs/cli/src/infty/commands.rs +++ b/codex-rs/cli/src/infty/commands.rs @@ -106,14 +106,14 @@ pub(crate) async fn run_create( } else { println!("{location_line}"); } - if let Some(objective_text) = options.objective.as_deref() { - if !objective_text.trim().is_empty() { - let objective_line = format!(" objective: {objective_text}"); - if color_enabled { - println!("{}", objective_line.dimmed()); - } else { - println!("{objective_line}"); - } + if let Some(objective_text) = options.objective.as_deref() + && !objective_text.trim().is_empty() + { + let objective_line = format!(" objective: {objective_text}"); + if color_enabled { + println!("{}", objective_line.dimmed()); + } else { + println!("{objective_line}"); } } println!(); @@ -315,7 +315,7 @@ fn resolve_runs_root(override_path: Option) -> Result { if let Some(path) = override_path { return Ok(path); } - Ok(codex_infty::default_runs_root()?) + codex_infty::default_runs_root() } fn collect_run_summaries(root: &Path) -> Result> { diff --git a/codex-rs/cli/src/infty/progress.rs b/codex-rs/cli/src/infty/progress.rs index 5a7d4e9b70..8f68a23369 100644 --- a/codex-rs/cli/src/infty/progress.rs +++ b/codex-rs/cli/src/infty/progress.rs @@ -118,14 +118,14 @@ impl ProgressReporter for TerminalProgressReporter { } else { println!("{line}"); } - if let Some(notes) = notes { - if !notes.is_empty() { - let notes_line = format!(" notes: {notes}"); - if self.color_enabled { - println!("{}", notes_line.dimmed()); - } else { - println!("{notes_line}"); - } + if let Some(notes) = notes + && !notes.is_empty() + { + let notes_line = format!(" notes: {notes}"); + if self.color_enabled { + println!("{}", notes_line.dimmed()); + } else { + println!("{notes_line}"); } } } @@ -203,14 +203,14 @@ impl ProgressReporter for TerminalProgressReporter { } else { println!("{line}"); } - if let Some(summary) = summary { - if !summary.is_empty() { - let hint = " (final summary will be shown below)"; - if self.color_enabled { - println!("{}", hint.dimmed()); - } else { - println!("{hint}"); - } + if let Some(summary) = summary + && !summary.is_empty() + { + let hint = " (final summary will be shown below)"; + if self.color_enabled { + println!("{}", hint.dimmed()); + } else { + println!("{hint}"); } } } diff --git a/codex-rs/cli/src/infty/summary.rs b/codex-rs/cli/src/infty/summary.rs index b2a19f3d55..8325f5a202 100644 --- a/codex-rs/cli/src/infty/summary.rs +++ b/codex-rs/cli/src/infty/summary.rs @@ -19,10 +19,10 @@ pub(crate) fn print_run_summary_box( let mut items = Vec::new(); items.push(("Run ID".to_string(), run_id.to_string())); items.push(("Run Directory".to_string(), run_path.display().to_string())); - if let Some(objective) = objective { - if !objective.trim().is_empty() { - items.push(("Objective".to_string(), objective.trim().to_string())); - } + if let Some(objective) = objective + && !objective.trim().is_empty() + { + items.push(("Objective".to_string(), objective.trim().to_string())); } items.push(( "Deliverable".to_string(), @@ -92,7 +92,7 @@ pub(crate) fn print_run_summary_box( if wrapped.is_empty() { rows.push(String::new()); } else { - rows.extend(wrapped.into_iter().map(|line| line.into_owned())); + rows.extend(wrapped.into_iter().map(std::borrow::Cow::into_owned)); } } if rows.is_empty() { @@ -101,13 +101,7 @@ pub(crate) fn print_run_summary_box( for (line_idx, line) in rows.iter().enumerate() { let label_cell = if line_idx == 0 { label.as_str() } else { "" }; - let row_line = format!( - "| {label_cell: println!("{}", row_line.green()), diff --git a/codex-rs/codex-infty/src/orchestrator.rs b/codex-rs/codex-infty/src/orchestrator.rs index c94cf4fe6d..59919ba0d6 100644 --- a/codex-rs/codex-infty/src/orchestrator.rs +++ b/codex-rs/codex-infty/src/orchestrator.rs @@ -430,23 +430,13 @@ impl InftyOrchestrator { if let Some(progress) = self.progress.as_ref() { progress.final_delivery(&resolved, summary_ref); } - let verified = self - .run_final_verification( - sessions, - &resolved, - summary_ref, - options, - ) - .await?; sessions.store.touch()?; - if verified { - return Ok(RunOutcome { - run_id: sessions.run_id.clone(), - deliverable_path: resolved, - summary: summary_clean, - raw_message: agent_msg.message.clone(), - }); - } + return Ok(RunOutcome { + run_id: sessions.run_id.clone(), + deliverable_path: resolved, + summary: summary_clean, + raw_message: agent_msg.message.clone(), + }); } } }