Repository navigation
Conversation
自动化的审批策略原来是写死的,无人值守时所有需要确认的操作都会被直接拒绝, 需要读写工作区外目录或访问外部域名的任务因此无法完成。现在每个自动化保存 自己的权限模式,并在智能审批下维护一份目录与域名白名单,无人值守的运行命中 白名单时免确认放行。 - 新增 approval_policy 与 approval_allowlist_json(迁移 v31),随执行快照与运行记录传递。 - 权限引擎仅在白名单覆盖时对无人值守运行保留批准;deny、宿主机 shell、系统动作、 人工审批与只读限制保持不变。 - 创建工具与确认卡片支持 approvalPolicy / approvalAllowlist,编辑器只读展示白名单; 权限选择器恢复人工审批,并补充后台说明。 - 新增无人值守权限矩阵回归测试。 Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
沿用上游新增的 containsCanonicalPath 判断免确认白名单中的目录包含关系。 Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
上游同期新增了 v31(MutationRecovery),免确认白名单对应的列迁移改为 v32。 Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
该用例通过拨回 user_version 模拟 v30 旧库,重新打开时会再次执行 v31 与 v32, 而自动化审批列已存在导致 duplicate column name。模拟旧库时同步去掉这两列。 Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Contributor
|
这部分我会在你基础上稍微调整下:
|
Contributor
|
还有部分拦截可能是设计缺陷、不友好 |
Contributor
|
推倒的有点多,还是新起了一个 #409 这个将会关闭 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
背景与关联 / Context and related issue
主要改动 / Changes
approval_policy(迁移 v31),编辑器的权限选择器与聊天一致,恢复「人工审批」,并把后台说明改为「无人值守时需要确认的操作会被拒绝」。approval_allowlist_json(同一迁移 v31),条目为目录(读/写)和域名(精确或*.前缀)。无人值守的运行遇到需要确认的操作时,只有白名单覆盖才放行,且只对这一次调用有效,不写入长期授权。deny、宿主机 shell、系统动作、人工审批和只读限制均不变。approvalPolicy与approvalAllowlist,工具说明要求 AI 先判断任务是否需要工作区外的目录或域名;白名单显示在创建确认卡片上,由用户确认后才生效。验证 / Verification
unattendedPermissionMatrix.spec.ts)。这些在移植到本分支之前已在我们的开发分支上通过类型检查与相关 spec;移植到上游 master 后未重复本地验证,请以本 PR 的 CI 为准。DesktopAutomationEditor.vue的一处冲突,并把两列合并到同一个迁移 v31);Windows/macOS 应用内手动验证。兼容与风险 / Compatibility and risks
policy+ 空白名单处理,行为不变。若上游同期也新增 v31,需要调整编号。PermissionEngine.finalizeDecision与ToolAuthorizationService中后台放行的分支,以及approvalAllowlist.ts的路径/域名匹配。界面变更 / UI changes
自动化编辑器新增只读的「免确认范围」区块,权限选择器在后台新增「人工审批」及后台说明。暂未附截图。
🤖 Generated with Claude Code