Skip to content

refactor: delegate filesystem enforcement to sandbox extension#17

Merged
kostyay merged 3 commits into
mainfrom
refactor/delegate-filesystem-enforcement
Mar 3, 2026
Merged

refactor: delegate filesystem enforcement to sandbox extension#17
kostyay merged 3 commits into
mainfrom
refactor/delegate-filesystem-enforcement

Conversation

@kostyay
Copy link
Copy Markdown
Owner

@kostyay kostyay commented Mar 3, 2026

  • Remove 100+ lines of destructive command pattern matching logic from plan-ask extension; filesystem enforcement now delegated to sandbox via event-based communication
  • Add readonly event emitted on pi.events to signal read-only mode to sandbox extension, which dynamically reconfigures filesystem restrictions
  • Simplify plan-ask to only manage tool restrictions (edit/write removal) and system prompts; emit readonly events when entering/exiting restricted modes
  • Add user notification in plan-ask if sandbox extension is not loaded to inform that filesystem write enforcement is inactive
  • Update sandbox extension to listen for readonly events and toggle filesystem write permissions dynamically, with acknowledgment mechanism
  • Display [READONLY] indicator in sandbox status when filesystem is restricted
  • Add sandbox status display on line 3 of status bar (shown only when sandbox extension is active)
  • Add status bar documentation noting sandbox status appears on dedicated line 3

@kostyay kostyay changed the title WIP refactor: delegate filesystem enforcement to sandbox extension Mar 3, 2026
@kostyay kostyay merged commit b6cf364 into main Mar 3, 2026
@kostyay kostyay deleted the refactor/delegate-filesystem-enforcement branch March 3, 2026 11:26
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.

1 participant