codex: fix app-server sandbox setup build on PR #15329

Co-authored-by: Codex <noreply@openai.com>
This commit is contained in:
Ahmed Ibrahim
2026-03-20 19:19:23 +00:00
co-authored by Codex
parent 877678189f
commit 1e3584ab5c
@@ -7212,16 +7212,18 @@ impl CodexMessageProcessor {
codex_home: codex_home.clone(),
originator_tag: Some(originator().value),
};
run_windows_sandbox_setup(setup_request).await?;
ConfigEditsBuilder::new(codex_home.as_path())
.with_profile(active_profile.as_deref())
.set_windows_sandbox_mode(windows_sandbox_mode_tag(mode))
.clear_legacy_windows_sandbox_keys()
.apply()
.await
.map_err(|err| {
anyhow::anyhow!("failed to persist windows sandbox mode: {err}")
})
match run_windows_sandbox_setup(setup_request).await {
Ok(()) => ConfigEditsBuilder::new(codex_home.as_path())
.with_profile(active_profile.as_deref())
.set_windows_sandbox_mode(windows_sandbox_mode_tag(mode))
.clear_legacy_windows_sandbox_keys()
.apply()
.await
.map_err(|err| {
anyhow::anyhow!("failed to persist windows sandbox mode: {err}")
}),
Err(err) => Err(err),
}
}
Err(err) => Err(err.into()),
};