Skip to content

Soften explicit command approval prompts - #3953

Merged
max-sixty merged 2 commits into
mainfrom
codex/gentler-approval-prompt
Aug 29, 2026
Merged

Soften explicit command approval prompts#3953
max-sixty merged 2 commits into
mainfrom
codex/gentler-approval-prompt

Conversation

@max-sixty

@max-sixty max-sixty commented Aug 29, 2026

Copy link
Copy Markdown
Owner

Use a neutral heading when wt config approvals add reviews or records commands. Approval prompts that interrupt command execution keep the warning.

This was written by Codex on behalf of max-sixty

@worktrunk-bot worktrunk-bot left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The caller split is clean — approve_command_batch still routes the execution gate through the yellow prompt_for_batch_approval, and announce_batch_approval has add_approvals as its only caller, so nothing that interrupts an operation lost its warning. Three follow-ups, none blocking.

Stale doc link on announce_batch_approval. Its docstring still reads "Lives beside [prompt_for_batch_approval] so the two headers stay parallel". After this split the parallel header is prompt_for_batch_review's — both go through info_message — while prompt_for_batch_approval is the one that deliberately diverges, so the comment now names the wrong sibling. That line sits just outside the diff hunk, so no suggestion block; the fix is:

/// unattended run just approved. Lives beside [`prompt_for_batch_review`]
/// so the two headers stay parallel.

prompt_for_batch_approval no longer needs pub. With config/approvals.rs importing prompt_for_batch_review instead, its only remaining caller is approve_command_batch in the same module.

The new header carries the same symbol as the rows it introduces. info_message prefixes dim , and print_command_batch prefixes every command label with INFO_SYMBOL, so the batch now renders with no visual break between the header and its list:

○ Approving 2 commands for repo (--yes):
○ pre-merge:
   cargo test
○ alias deploy:
   echo deploying {{ branch }}

The yellow was doing that separation before. wt config approvals list hits the same problem and answers it with format_heading — cyan APPROVED / UNAPPROVED, no symbol — reserving and for rows; prompt_message's would also read as "awaiting input" on the interactive add path. Either keeps the header distinct without bringing back the warning framing. Worth a look since it's the part of the change the snapshots make visible.

Happy to push the docstring and visibility fixes if you'd like them.

@max-sixty
max-sixty merged commit 5895c41 into main Aug 29, 2026
40 checks passed
@max-sixty
max-sixty deleted the codex/gentler-approval-prompt branch August 29, 2026 03:20
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.

2 participants