mirror of
https://github.com/openai/codex.git
synced 2026-11-02 19:43:24 +00:00
Silence interrupted pre-turn compaction failures
This commit is contained in:
@@ -4689,6 +4689,7 @@ async fn maybe_run_previous_model_inline_compact(
|
||||
.await
|
||||
{
|
||||
Ok(()) => Ok(()),
|
||||
Err(CodexErr::Interrupted) => Err(()),
|
||||
Err(err) => {
|
||||
if !pre_turn_context_items.is_empty() {
|
||||
// Preserve model-visible settings updates even when pre-turn compaction fails
|
||||
@@ -4800,6 +4801,9 @@ async fn run_pre_turn_auto_compaction_if_needed(
|
||||
.await;
|
||||
|
||||
if let Err(err) = compact_result {
|
||||
if matches!(err, CodexErr::Interrupted) {
|
||||
return Err(());
|
||||
}
|
||||
if !pre_turn_context_items.is_empty() {
|
||||
// Preserve model-visible settings updates even when pre-turn compaction fails
|
||||
// before we can persist turn input.
|
||||
|
||||
Reference in New Issue
Block a user