Repository navigation
ask: rules in bot front matter, since auto mode rarely asks - #557
Conversation
A bot's ask list always goes to the 👍/👎 comment, even when auto mode or allow would let the call through. loopway passes the list to Claude Code with --settings, and deny beats ask beats allow. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
|
The code for #517 is up in this PR and all five checks pass (257 CLI tests, 41 web). I'm blocked on the live steps. Claude Code's auto mode refused the command that starts the sandbox run: Reply here to answer: loopway-bot is waiting. |
|
Blocked: there is no What I ranOn
Must fix
Worth considering
|
|
This PR conflicts with its base branch. Rebase onto it, resolve the conflicts, and push. |
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
|
Blocked: the merge with What I ranOn
Must fix
|
Closes #517.
A bot's front matter gets an
ask:list, besideallow:anddeny:. A call that matches it always goes to the 👍/👎 comment, even when auto mode would have allowed it.What it does
ask: [...]in a bot's front matter: tool patterns in Claude Code's syntax, validated likeallowanddeny.--settings '{"permissions":{"ask":[...]}}', so Claude Code sends matching calls to the permission tool instead of auto mode deciding. No flag is added when the list is empty.denybeatsask, andaskbeatsallow. A call that matchesaskskipsallowand is put to the owner. An approved call still passes on its retry.init-scratchwrites a commented-out# ask: ["Bash(curl:*)"]intodev.md.docs/developing.mdandCHANGELOG.mdupdated; CLI version raised to 2.0.3.Worth knowing
--settingswith inline JSON rather than a generated file, so nothing is written to disk and the project's own.claude/settings.jsonis not touched. Whether Claude Code really routes the call to the permission tool is what the live steps check.denyis checked in the permission tool, as before. Anaskpattern that also matches adenypattern is refused without asking.Test it locally
npm run build && npm test && npm run typecheck && npm run lint && npm run format:checkNew tests:
claude.test.ts(the--settingsarg is present with ask rules, absent without),asks.test.ts(parsingask, deny > ask > allow, anallowed call that matchesaskis asked then passes once approved, and the run receives the patterns),init-scratch.test.ts(the commented example).To try it live, follow the steps in #517. The record is
verifications/<pr>.mdon the branch (being written).🤖 Generated with Claude Code