Revert "Fix remote exec env overlay CI failures"

This reverts commit 05f23aebae.
This commit is contained in:
pakrym-oai
2026-04-10 19:33:07 -07:00
parent 05f23aebae
commit 71279f0f58
2 changed files with 14 additions and 16 deletions

View File

@@ -655,13 +655,7 @@ impl UnifiedExecProcessManager {
environment: &codex_exec_server::Environment,
) -> Result<UnifiedExecProcess, UnifiedExecError> {
let inherited_fds = spawn_lifecycle.inherited_fds();
if environment.is_remote() {
if !inherited_fds.is_empty() {
return Err(UnifiedExecError::create_process(
"remote exec-server does not support inherited file descriptors".to_string(),
));
}
if inherited_fds.is_empty() {
let started = environment
.get_exec_backend()
.start(exec_server_params_for_request(process_id, request, tty))
@@ -671,6 +665,12 @@ impl UnifiedExecProcessManager {
return UnifiedExecProcess::from_exec_server_started(started, request.sandbox).await;
}
if environment.is_remote() {
return Err(UnifiedExecError::create_process(
"remote exec-server does not support inherited file descriptors".to_string(),
));
}
let (program, args) = request
.command
.split_first()

View File

@@ -695,14 +695,12 @@ mod tests {
include_only: Vec::new(),
});
let mut expected = HashMap::from([
("OVERLAY".to_string(), "overlay".to_string()),
("POLICY_SET".to_string(), "overlay-wins".to_string()),
]);
if cfg!(target_os = "windows") {
expected.insert("PATHEXT".to_string(), ".COM;.EXE;.BAT;.CMD".to_string());
}
assert_eq!(child_env(&params), expected);
assert_eq!(
child_env(&params),
HashMap::from([
("OVERLAY".to_string(), "overlay".to_string()),
("POLICY_SET".to_string(), "overlay-wins".to_string()),
])
);
}
}