Skip to content

fix(agent): enforce plan mode write restrictions#1301

Open
YOMXXX wants to merge 1 commit into
XiaomiMiMo:mainfrom
YOMXXX:fix/870-plan-mode-permissions
Open

fix(agent): enforce plan mode write restrictions#1301
YOMXXX wants to merge 1 commit into
XiaomiMiMo:mainfrom
YOMXXX:fix/870-plan-mode-permissions

Conversation

@YOMXXX

@YOMXXX YOMXXX commented Jun 24, 2026

Copy link
Copy Markdown

Summary

  • enforce plan-mode write restrictions after user and session permission merges
  • deny shell/task/workflow/directory changes in plan mode while preserving plan-file edits
  • keep persisted approvals from overriding explicit deny rules and constrain plan-spawned subagents to read-only tools

Fixes #870
Fixes #1274

Verification

  • bun test test/agent/agent.test.ts test/agent/plan-permission.test.ts test/permission/next.test.ts test/tool/actor.test.ts --timeout 30000
  • bun typecheck
  • git diff --check

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.

plan模式下,依旧可以修改文件 mimo-code不遵循plan模式

1 participant