Treat compaction failure as failure state (#10927)

- Return compaction errors from local and remote compaction flows.\n-
Stop turns/tasks when auto-compaction fails instead of continuing
execution.
This commit is contained in:
Ahmed Ibrahim
2026-02-06 13:51:46 -08:00
committed by GitHub
parent 1751116ec6
commit ba8b5d9018
6 changed files with 258 additions and 46 deletions

View File

@@ -105,6 +105,7 @@ async fn auto_compaction_local_emits_started_and_completed_items() -> Result<()>
#[tokio::test(flavor = "multi_thread", worker_threads = 2)]
async fn auto_compaction_remote_emits_started_and_completed_items() -> Result<()> {
skip_if_no_network!(Ok(()));
const REMOTE_AUTO_COMPACT_LIMIT: i64 = 200_000;
let server = responses::start_mock_server().await;
let sse1 = responses::sse(vec![
@@ -146,7 +147,7 @@ async fn auto_compaction_remote_emits_started_and_completed_items() -> Result<()
codex_home.path(),
&server.uri(),
&BTreeMap::default(),
AUTO_COMPACT_LIMIT,
REMOTE_AUTO_COMPACT_LIMIT,
Some(true),
"openai",
COMPACT_PROMPT,