allow editing sandbox prompt rules#38
Conversation
There was a problem hiding this comment.
Pull request overview
Adds an “edit rule” workflow to sandbox permission prompts so users can adjust the domain/path rule before granting access, with validation to ensure the edited rule still matches the blocked domain/path.
Changes:
- Extends permission prompt handling to return both the chosen scope (session/project/global/abort) and the (possibly edited) rule value.
- Adds inline editing UI (Tab to edit) for allow options, including validation feedback.
- Applies the edited rule value when persisting/updating allowlists and updates related user-facing messages.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
Hi @bnii this is a really nice change, but I'm a bit averse to accepting such big changes until I've refactored the codebase to the point it's a bit more maintainable. It's purely because (a) I don't spend much time on this and (b) I'd much rather the project stagnates than accidentally ship vulnerabilities. I'll leave this here for a bit, and if I get the time to either do the refactor (really just splitting out files a bit) or review it then I'll let you know. |
makes sense, thanks! |
|
Really great change. |
Adds an editable rule field to sandbox permission prompts (claude code like)
When a read/write/domain permission prompt appears, pressing tab on an
allow option lets the user adjust the rule before granting it. This makes
it possible to add broader patterns
Edited rules are validated against the domain/path before being applied.