feat(buzz-acp): add auto permission mode - #2885
Open
skyerus wants to merge 2 commits into
Open
Conversation
claude-agent-acp advertises six values for the `mode` config option, with
`auto` first in the list:
auto | default | acceptEdits | plan | dontAsk | bypassPermissions
`PermissionMode` omitted `auto`, so `BUZZ_ACP_PERMISSION_MODE=auto` failed
clap validation at startup and the value could never reach the adapter.
`auto` is the mode a headless harness actually wants. buzz-acp auto-approves
every `session/request_permission` with `allow_once`, which is correct — there
is no human at a terminal to answer one — but it means `default` and
`acceptEdits` are indistinguishable from `bypassPermissions` in practice, and
the only modes that constrain anything are `plan` and `dontAsk`, which are too
restrictive for real work. `auto` keeps a classifier reviewing each tool call
without requiring a prompt to be answered.
Tests cover the wire string, `is_default`, and both the kebab-case and
camelCase parse paths, matching the existing per-mode coverage.
Signed-off-by: Skye Gill <skyerusgill@gmail.com>
skyerus
force-pushed
the
feat/acp-auto-permission-mode
branch
from
July 25, 2026 19:51
a1c509a to
bdfd18e
Compare
Co-authored-by: Phuoc (Phu) Do <91568955+dophsquare@users.noreply.github.com> Signed-off-by: Phuoc (Phu) Do <91568955+dophsquare@users.noreply.github.com> * origin/main: (111 commits) chore(ci): bump desktop smoke E2E timeout to 30 minutes (block#3409) release(chart): publish 0.1.7 (block#3393) feat(acp): steer claude-code and codex agents via _session/steering (block#3007) feat(desktop): apply WebKit rendering workarounds at startup on Linux (block#3271) fix(desktop): stabilize flaky DM expansion E2E ordering assertions (block#2004) docs(contributing): document the Linux system libraries just ci requires (block#3396) fix(desktop): paint community rail full height (block#3382) fix(acp): disable goose cron scheduler in managed agent children (block#3144) feat(desktop): add custom harness inline from agent dialogs (block#3252) chore(compose): remove stale typesense env vars (block#3332) feat(desktop): refine agent catalog sharing (block#2439) fix(desktop): keep drafts out of the Inbox All view (block#3217) docs: restructure DCO guidance into scannable subsection (block#3337) Unify mobile loading spinners (block#3314) fix(desktop): restore the inbox icon in the sidebar (block#3341) fix(desktop): gate codex-acp on a minimum supported version (block#3254) feat(cli): add users set-status command for NIP-38 profile status (block#3253) fix(composer): scope multiline block formatting (block#3246) feat(chart): add relay pod extension points (block#3322) Refine mobile attachment picking (block#3313) ...
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #2884.
What this solves
buzz-acpcan't be put into Claude Code'sautopermission mode.PermissionModehas five variants andautoisn't one, soBUZZ_ACP_PERMISSION_MODE=autofails clap validation at startup and the value never reaches the adapter — even though the adapter advertises it.Probing
claude-agent-acp0.61.0 over ACP,session/newreturnsautofirst in themodeconfig option:Why
autois the mode this harness wantsbuzz-acpauto-approves everysession/request_permissionwithallow_once(acp.rs:1068,acp.rs:1671), which is correct for a chat-driven harness — there's no human at a terminal, and forwarding a prompt would hang the turn.The side effect is that
defaultandacceptEditsbecome indistinguishable frombypassPermissions, leaving onlyplananddontAskas modes that constrain anything, and both are too restrictive for real work.autois the missing middle: a classifier reviews each tool call, with no prompt for anyone to answer.Implementation
Two lines of behaviour — the enum variant and its wire string:
The
#[value(alias = "auto")]form matches the existing style (DefaultandPlancarry the same redundant-but-explicit alias). Doc comments on the enum and on the--permission-modearg updated to mention it.Tests
Extended the four existing per-mode tests rather than adding new ones, so
autois covered everywhere the other five are:test_permission_mode_wire_strings—"auto"test_permission_mode_is_default— not the defaulttest_permission_mode_value_enum_kebab_case—"auto"parsestest_permission_mode_value_enum_camel_case_aliases— alias pathcargo fmt -p buzz-acp -- --checkclean.cargo clippy -p buzz-acp --lib --all-featuresproduces no new warnings (the two it reports are pre-existing, both inqueue.rs).Testing it manually
Startup log should read
permission_mode=autowhere it previously rejected the value.Deferred
Not addressed here: whether the adapter honours
autoidentically to the interactive CLI. agentclientprotocol/claude-agent-acp#607 reportspermissions.defaultMode: "auto"insettings.jsonhaving no effect, though that's a different mechanism fromsession/set_config_option— which is the path this uses and the one the adapter advertises. Worth verifying end-to-end before relying on the classifier as a security control.