Fix sandbox permission accessors after rebase

This commit is contained in:
Eva Wong
2026-04-27 08:46:38 -07:00
parent a88760e8e2
commit 3ae2e24e72
3 changed files with 5 additions and 3 deletions

View File

@@ -149,7 +149,7 @@ async fn run_command_under_sandbox(
if let Some(reason) = codex_shell_command::preserved_path_write_forbidden_reason(
&command,
cwd.as_path(),
&config.permissions.file_system_sandbox_policy,
&config.permissions.file_system_sandbox_policy(),
) {
anyhow::bail!("{reason}");
}

View File

@@ -534,7 +534,7 @@ impl ShellHandler {
let exec_approval_requirement = codex_shell_command::preserved_path_write_forbidden_reason(
&exec_params.command,
&exec_params.cwd,
&turn.file_system_sandbox_policy,
&file_system_sandbox_policy,
)
.map_or(exec_approval_requirement, |reason| {
crate::tools::sandboxing::ExecApprovalRequirement::Forbidden { reason }

View File

@@ -1132,7 +1132,9 @@ fn permission_profile_override_from_config(
}
if matches!(
config.permissions.sandbox_policy.get(),
config
.permissions
.legacy_sandbox_policy(config.cwd.as_path()),
SandboxPolicy::ExternalSandbox { .. }
) {
None