From 6989c6548b3737f108e2bb5ae1171b1d2032e30c Mon Sep 17 00:00:00 2001 From: Sean Huang Date: Thu, 24 Sep 2026 00:44:15 +0000 Subject: [PATCH] Fix spawn flag typing and isolate project configuration tests (#47704) ## What changed - Cast `POSIX_SPAWN_SETSID` to the inferred flag type in the `ProcessMode::NewSession` branch. - Use `LoaderOverrides::without_managed_config_for_tests()` for both cases in `project_layers_disabled_when_untrusted_or_unknown` so host-managed configuration does not affect the test. GitOrigin-RevId: 1b27ac3ea139507d3f9402f4c2e3e63933c4d05c --- codex-rs/core/src/config/config_loader_tests.rs | 4 ++-- codex-rs/utils/pty/src/posix_child.rs | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/codex-rs/core/src/config/config_loader_tests.rs b/codex-rs/core/src/config/config_loader_tests.rs index 1257a40c0f..d50816a84d 100644 --- a/codex-rs/core/src/config/config_loader_tests.rs +++ b/codex-rs/core/src/config/config_loader_tests.rs @@ -3756,7 +3756,7 @@ profile = "ignored" &codex_home_untrusted, Some(cwd.clone()), &[] as &[(String, TomlValue)], - LoaderOverrides::default(), + LoaderOverrides::without_managed_config_for_tests(), &codex_config::NoopThreadConfigLoader, ) .await?; @@ -3798,7 +3798,7 @@ profile = "ignored" &codex_home_unknown, Some(cwd), &[] as &[(String, TomlValue)], - LoaderOverrides::default(), + LoaderOverrides::without_managed_config_for_tests(), &codex_config::NoopThreadConfigLoader, ) .await?; diff --git a/codex-rs/utils/pty/src/posix_child.rs b/codex-rs/utils/pty/src/posix_child.rs index 73ce7b2995..196f6693e7 100644 --- a/codex-rs/utils/pty/src/posix_child.rs +++ b/codex-rs/utils/pty/src/posix_child.rs @@ -203,7 +203,7 @@ impl NativeChild { ))?; libc::POSIX_SPAWN_SETPGROUP } - crate::ProcessMode::NewSession => POSIX_SPAWN_SETSID, + crate::ProcessMode::NewSession => POSIX_SPAWN_SETSID as _, }; let mut defaults = std::mem::zeroed(); cvt_errno(libc::sigemptyset(&mut defaults))?;