Skip to content

/always-approve in a Grok Build session does not stop bash permission cards #114

Description

@mattpanther

Description

In a Grok Build chat on Android, /always-approve does nothing visible and does not stop bash permission cards. Reads go through. Every shell command still waits for a tap.

Grok's own docs treat /always-approve as a session toggle: on → skip ordinary tool prompts; run it again → back to ask. On the desktop TUI that is a status badge. In Shellular there is no toast, no badge, and bash still prompts.

I am not asking to turn always-approve on for every Grok session. Permission cards are useful as the default. I want the command that is already in the slash menu to actually flip this session.

Steps to reproduce

  1. Pair the Android app with the host CLI.
  2. Open Grok Build on a trusted repo.
  3. Ask it to run a non-readonly shell command (anything other than ls / git status / similar).
  4. Approve the permission card.
  5. Run /always-approve from the composer.
  6. Ask for another shell command.

Expected

A confirmation that always-approve is on for this session. Later bash calls run without a card. Running /always-approve again returns to asking.

Actual

Step 5 is silent. Step 6 shows another bash card.

This session's Grok event log still had yolo_mode: true on every turn, including after the slash command, and there was no mode-change event. Bash still blocked on the client:

Tool wait_ms
grep / list_dir / read_file 0
run_terminal_command (before /always-approve) 3292
run_terminal_command (after /always-approve) 7800
Unique write (mkdir + printf to /tmp) to reproduce 11436

So the phone is still the approver. Grok thinks yolo is already on; the slash command neither confirms that nor changes Shellular's handling of session/request_permission.

Environment

  • App: Shellular 0.0.43 (43) on a Pixel 10 Pro (Android)
  • Host: macOS, npx shellular / host agent
  • Grok Build: 1.0.13 (grok agent stdio)
  • ~/.grok/config.toml has permission_mode = "always-approve" (and, after we noticed a split with the legacy key, yolo = true)
  • Project is trusted

Where it looks like it breaks

Host spawn does not pass Grok's always-approve flag:

https://github.com/shellular-org/packages/blob/main/cli/src/agents/agents.ts

"grok-build": {
  spawn: {
    command: "grok",
    args: ["agent", "stdio"],
  },
},

session/new does not set _meta.yoloMode. Grok documents that as the ACP way to put a session in always-approve:

The host then forwards session/request_permission to the app, which is correct for ask mode. /always-approve never changes that path, and the app does not show that the toggle ran. Grok documents it as a silent toggle that turns off if you run it while already on — so a no-op on the phone is easy to misread.

This is the same ACP-client gap as Paseo #2053 (no Always-approve control for Grok). It is not xAI plugin-marketplace #209 (Allow does nothing and the tool is cancelled). Here Allow works; you just have to tap every time.

Proposed fix (session toggle, not a new default)

Keep tap-to-approve as the default. When the user runs /always-approve in a Grok session:

  1. Treat it as a per-session toggle (on / off), same as Grok's TUI.
  2. Show a toast or badge so it is not silent.
  3. While on, either:
    • tell Grok (session/setMode if advertised, or _meta.yoloMode on session/new / equivalent), so it stops sending bash session/request_permission, or
    • auto-answer those RPCs on the host/app side for this session only.

A follow-up in shellular-org/app may be needed for the toast/badge. I would not spawn grok agent --always-approve stdio for every Grok session.

Happy to send a PR against packages (and app dev if you want the UI) once you say which of those two "while on" options you prefer.

Workaround

Approve each bash card, or run a custom agent that launches grok agent --always-approve stdio. The custom agent is a frozen argv and drifts from the builtin grok-build adapter, so I would rather have the slash command work.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions