Skip to content

fix: preserve resolved prompt permissions - #503

Open
kocaemre wants to merge 1 commit into
agentclientprotocol:mainfrom
kocaemre:fix/preserve-resolved-prompt-permissions
Open

fix: preserve resolved prompt permissions#503
kocaemre wants to merge 1 commit into
agentclientprotocol:mainfrom
kocaemre:fix/preserve-resolved-prompt-permissions

Conversation

@kocaemre

Copy link
Copy Markdown

Summary

  • Preserve the Codex app-server's resolved default approval/reviewer/sandbox settings in session metadata.
  • Use those resolved permissions for default Agent prompts instead of reapplying the hardcoded default Agent preset.
  • Keep explicit non-default mode behavior unchanged, and continue adding ACP additionalDirectories to workspace-write roots.
  • Add regression coverage for configured writable roots/network access and explicit mode overrides.

Closes #477

Test Plan

  • npm run typecheck
  • npx vitest run src/__tests__/CodexACPAgent/CodexAcpClient.test.ts --testNamePattern 'preserves resolved default prompt permissions|uses explicit non-default mode prompt permissions|applies ACP additional directories'
  • npx vitest run src/__tests__/CodexACPAgent/CodexAcpClient.test.ts
  • git diff --check

Note: the full targeted test file prints existing stderr log lines from auth/rate-limit negative-path tests, but the Vitest run exited successfully with 107/107 tests passing.

Signed-off-by: Emre K <110906681+kocaemre@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Default Agent prompts overwrite configured writable roots and sandbox permissions

1 participant