diff --git a/codex-rs/core/src/thread_manager.rs b/codex-rs/core/src/thread_manager.rs index 5a00027fda..35c1bcc99b 100644 --- a/codex-rs/core/src/thread_manager.rs +++ b/codex-rs/core/src/thread_manager.rs @@ -869,12 +869,7 @@ fn snapshot_fork_history( snapshot_mode: ForkSnapshotMode, ) -> InitialHistory { match (history, snapshot_mode) { - (InitialHistory::New, ForkSnapshotMode::Committed) => InitialHistory::New, - (InitialHistory::New, ForkSnapshotMode::Interrupted) => { - InitialHistory::Forked(vec![RolloutItem::ResponseItem( - interrupted_turn_history_marker(), - )]) - } + (InitialHistory::New, _) => InitialHistory::New, (InitialHistory::Forked(history), ForkSnapshotMode::Committed) => { InitialHistory::Forked(history) } diff --git a/codex-rs/core/src/thread_manager_tests.rs b/codex-rs/core/src/thread_manager_tests.rs index 70a96726cb..57228a1821 100644 --- a/codex-rs/core/src/thread_manager_tests.rs +++ b/codex-rs/core/src/thread_manager_tests.rs @@ -210,9 +210,7 @@ fn interrupted_fork_snapshot_appends_interrupt_marker() { .get_rollout_items() ) .expect("serialize interrupted empty fork history"), - serde_json::to_value(vec![RolloutItem::ResponseItem( - interrupted_turn_history_marker(), - )]) - .expect("serialize expected interrupted empty fork history"), + serde_json::to_value(Vec::::new()) + .expect("serialize expected interrupted empty fork history"), ); }