Skip to content

feat(plugins): 支持标准 MCP Apps 交互页面与独立授权 - #7924

Open
fmfsaisai wants to merge 35 commits into
mainfrom
feat/plugin-ui-bridge
Open

fmfsaisai wants to merge 35 commits into
mainfrom
feat/plugin-ui-bridge

Conversation

@fmfsaisai

@fmfsaisai fmfsaisai commented Oct 29, 2026 •

Copy link
Copy Markdown
Collaborator

这次改了什么

摘要

插件可以给原有工具增加标准 MCP Apps 交互页面。模型仍通过 ghost_call 调用,页面通过宿主桥接到同一个 main.js 工具处理函数,复用现有联网、文件、媒体和任务权限。无需另起插件 MCP 进程或另配远程认证。

同时修复页面审批挤动对话、卡片高度反馈及滚轮冲突,并让手机和同账号远程查看端能确认页面能力。

变更类型

  • feat 新功能
  • fix 缺陷修复
  • refactor / perf 重构或性能优化
  • docs / test / chore 文档、测试或工程维护

范围

  • 关联 Issue / 需求:Refs bug(mcp-apps): 页面调用工具固定 60 秒超时;系统选择框不随调用取消关闭 #7748。本 PR 处理了其中插件页面相关的部分(续时、迟到选择不落盘、插件页面不再 60 秒断开);自定义 MCP 页面调用 60 秒超时、取消时不物理关闭系统面板仍未解决,bug(mcp-apps): 页面调用工具固定 60 秒超时;系统选择框不随调用取消关闭 #7748 保持开启。
  • 本 PR 包含:v3 可选顶层 mcpApps.ui.resources / mcpApps.ui.tools、宿主内虚拟 MCP 服务、页面文件能力、本机及同账号跨端确认、卡片审批与布局修复。
  • 明确不包含:宿主直连插件 stdio/HTTPS MCP、mcp.json、额外模型 MCP 登记、server 修改、跨端文件流、取消调用时物理关闭系统文件面板。
  • 用户可见变化:插件工具可返回表单和图表;页面可经插件选择/保存/上传文件、向 AI 发图、显示进度;自定义 MCP 页面的审批悬浮在输入框上方,同任务内可记住页面工具授权;页面外部消息仍不视作主人授权。
  • 是否存在 breaking change:无。新字段可选,旧插件功能和批准记录保留;未确认的新页面能力仅退化成文字结果,不要求重装或重配。旧 Host 保留顶层未知字段但不授权页面。
  • 发版版本:PLUGIN_UI_MIN_CINDY_VERSION 已定为 0.1.122-beta,与 Server 新 PR 同值。只影响打包声明下限和市场兼容版本投影,不是客户端安装闸门。

页面工具审批

页面调用本插件 app-visible 工具时,Main 按已安装插件身份构造 ghost_call 参数,复用 AI 调用的工具审批策略;点击、加载和定时器触发不再区别对待。auto-approve 工具沿用直接放行例外(含 cindy-art 媒体工具);其他工具在 Ask 下交给现有页面浮层,Auto 下统一审阅并注明“由插件交互页面发起”,Full Access 直接放行。prompt 可记住本任务的页面授权,prompt-each-time 不提供总是允许。页面授权与 AI 授权分开记录;工作目录写入等内部能力仍单独确认。一次性票据只绑定身份,不替代审批。

远程 Desktop 和 Mobile 继续通过同一交互请求通道回答,无新增协议;tester 已完成真实双 Desktop 的审批回答回归,执行端收到结果。手机界面没有人工测试。

UI 变化

卡片头显示插件名和信任等级;页面审批浮层与卡片内确认共用一个请求,不改变对话区高度;高度上限 5000,异常追涨锁高,保留正常滚动链。手机/远程遇到本机文件内容显示明确占位;普通页面仍可交互。所有新增文案覆盖五语,使用主题语义色。

  • 引用的设计规范:docs/design-rules/DESIGN.md §2 Color Palette & Roles(Light/Dark 语义色)、§3 Typography Rules、§5 的点击目标与圆角分类;审批不占输入框、不造成对话布局跳动。遵守 docs/product-rules/im-permission-confirmation.md 的同一最终决定原则。
  • 截图:见下表。均为 ui:check mock 数据和手册附带的公开示例插件,不含账号或本机信息;内部实测截图不公开。图片放在 fork 的独立素材分支 pr-assets/feat/plugin-ui-bridge,链接固定到提交,不属于本 PR 的代码改动。真实滚轮、标准 SDK/原生 JSON-RPC 页面已有独立 Electron 验证。
  • 先前全分支 ui:check:934/938 通过,4 个 chat-video 场景超时为已记录问题;未覆盖文件不算 UI 已验证。本轮未重复该整批截图检查。
Light Dark
页面审批浮层(输入框上方;ui:check mock,560 宽) 审批浮层 Light 审批浮层 Dark
手册附带的交互能力示例插件页面(800 宽) 示例页面 Light 示例页面 Dark

怎么验证的

自动验证

最终基于 origin/main=727afb1ad6 rebase,HEAD 为 b1db854af7。审批策略提交为 f93cf6178c,分享修复为 b1db854af7。仅自动生成的设计台账发生冲突,按合并后的源码重新生成;其余提交通过 range-diff 核对,产品语义不变。最终复验结果见下表及本地 tmp/e2e-plugin-ui/evidence/final-pr/ 日志。

命令 结果 完整输出(相对 tmp/e2e-plugin-ui/evidence/final-pr/)
pnpm --filter desktop typecheck 通过 desktop-typecheck.log
pnpm --filter mobile typecheck 通过 mobile-typecheck.log
pnpm --filter @cindy/plugin-protocol build 通过 protocol-typecheck.log
pnpm --filter @cindy/maker-core build 通过 core-typecheck.log
pnpm --filter cindy-tools build 通过 tools-typecheck.log
pnpm --filter desktop exec vitest run src/main/cindy-brain/__tests__/ghostLocalInstallIdentity.test.ts src/main/cindy-brain/__tests__/remotePluginManagement.test.ts src/main/cindy-brain/__tests__/ghostLocalFileIpc.test.ts src/main/plugin-market/__tests__/localSharing.test.ts src/main/cindy-brain/__tests__/fsSlot.test.ts src/main/cindy-brain/__tests__/ghostInstallConsent.test.ts src/main/cindy-brain/__tests__/ghostInstallConsentWindowBridge.test.ts src/main/cindy-brain/__tests__/ghostInstallReceipt.test.ts src/renderer/components/chat/__tests__/McpAppCard.test.tsx --pool=forks --maxWorkers=1 通过,9 文件 / 266 项 targeted.log
pnpm --filter desktop test:mcp-apps:conformance 通过,407 项 + SDK / 原生 JSON-RPC / wheel Electron 验证 conformance.log
pnpm --filter @cindy/maker-core exec vitest run src/agents/codex/index.test.ts -t 'captured App calls' --pool=forks --maxWorkers=1 通过,3 项;其余按名称筛选未运行 codex-overlap.log
pnpm check:test-hygiene 通过 test-hygiene.log
pnpm check:dco 通过,16 个提交 dco.log
pnpm check:design-inventory 通过 design-inventory.log
git diff --check 通过 diff-check.log
git diff origin/main --check 通过 branch-diff-check.log

此前集成验证记录在 tmp/e2e-plugin-ui/evidence/approval-share/ 和 pr-prep/verification.md:分享相关 124 项、审批及安装同意 239 项、conformance 407 项及三个 Electron verify 通过。F01 新用例先红后绿,所在文件 18 项测试执行 183ms、四文件定向总耗时 2.89s;通过真实分享安装和页面批准入口验证批准事实由 false 变为 true。

此前的整批验证与已知限制:

  • pnpm test:unit:related 因 lockfile 变更扩大为全套:Desktop 64024 项、Mobile 10649 项、maker-core 5985 项通过,其余 26 个 workspace 全通过。executor 2 项、maker-core auto-review 1 项仍为当时 main 上可复现的失败,保留 main 对照证据;不宣称全套全绿。本次最终 rebase 按影响面运行分享、审批、conformance 和 Codex 冲突重叠处的定向测试。
  • 历史兼容:协议包 228 项、Forge/真实安装与重启读取 117 项、真实市场安装升级 344 项通过。畸形历史声明不影响原工具,也不产生页面能力;同包本地新安装和新打包拒绝。
  • plugin-ui / plugin-files / mcp-apps-wheel 三个 Electron verify 通过。真实页面拖入三片共 2097155 字节,经 main.js 和 LibraryVault 落盘,回读字节一致。
  • i18n、glossary、test-hygiene、diff-check 通过;相同依赖环境下 iOS/Android 指纹与 main 一致。
  • 公开作者材料新增行的限制词扫描零命中;§4.7 原有说明和 tmp 内部演示保留。
  • 此前 codex review --uncommitted 因现有 CLI/模型兼容性 HTTP 400 无法完成;没有升级或换模型,已人工复核权限边界、冲突与净改动。正式 PR 将触发仓库自动 review。

新增测试的价值(§3.2)

以下均走生产入口;在新 worktree 单独运行,每个文件低于 5 秒。其余改写测试的规则依据及最小失败输入写在相邻注释中。

新增测试文件(apps/desktop/src/main 下) 生产入口、覆盖缺口和最小失败输入 tier 单独耗时
cindy-brain/tests/pickedFiles.test.ts importPickedFiles + LibraryVault;旧目录 pick 未覆盖流式文件导入。最小输入:一个图片魔数与扩展名不符的文件、撤销后的导入或超限文件,验证落库、配额和清理。 unit,隔离临时文件 1.861s
mcp-apps/tests/downloadFile.test.ts saveAppDownload;原宿主无草案下载能力。最小输入:不安全文件名、选择取消或 View 撤销,验证真实文件只在有效确认后发布。 unit,隔离临时文件 1.062s
mcp-apps/tests/pluginFileAccess.test.ts createPluginFileAccess;原网页资源无本插件文件授权。最小输入:suffix Range、另一插件的媒体指纹、文件软链,验证字节与拒绝边界。 unit,隔离临时文件 1.587s
mcp-apps/tests/pluginServer.test.ts 官方 MCP Client + createPluginAppTransport;原 HTTP 夹具未覆盖 main.js 桥接。最小输入:无票据/app 不可见工具/旧版本,验证 tools/resources 标准协议、单次票据和撤销。 unit,真实 SDK 内存 transport 1.212s
mcp-integrations/tests/pluginAppRegistry.test.ts refreshPluginApps;原 Apps Host 测试不拥有插件 receipt。最小输入:缺 ui 批准或账号变化后的回调,验证不读未授权页面、不向旧 owner 开放。 unit,真实 SDK,外部身份/存储桩 1.625s

手工验证

最后一轮 tester 在 rebase 前的 b852a50478 上完成 8 项补测,全部通过、没有新失败;报告为 tmp/e2e-plugin-ui/evidence/tester/regression-approval-share/report.md。最终 rebase 没有改变这两项修复的产品代码。

  1. Ask 显示输入框上方浮层及卡片等待状态,允许后执行,拒绝返回 MCP_APP_TOOL_DENIED。
  2. “本任务内总是允许”仅复用于同任务同工具,换工具或任务重新询问。
  3. 页面加载脚本自动调用同样审批,点击不构成特殊授权。
  4. Full Access 无审批;Auto 实际进入统一审阅后执行。来源说明只核对生产代码,没有抓取模型请求正文。
  5. 页面工具批准后,工作目录写入仍独立确认,确认后真实写入文件。
  6. 第二台 Desktop 回答审批,执行端页面收到结果;手机未测。
  7. 远程分享首装后页面仍未批准,正常提示条出现;单独确认后 uiCapabilityApproved=true,原安装 revision 不变,页面工具可用。
  8. Codex 真实打开插件卡;自定义 MCP 页面允许/拒绝行为保持不变。

原 worktree 的 tester 已验证三种 Agent 的工具出卡与历史任务冷恢复、远程普通页面、页面审批、滚轮和高度行为。修复后的真实双端复测见 tmp/e2e-plugin-ui/evidence/tester/final/retest-report.md:

  • M05 通过:远程 Desktop 经真实 device-link 连接,含 Library 文件的卡片显示「文件内容请在执行电脑查看」,普通 SDK 卡片仍可用;浅色、深色均已实测。
  • pick 卸载取消通过(派发器与存储范围):真实页面调用后卸载,派发器返回 CANCELLED,Library 和媒体未变化;未验证迟到选择,也不声称已卸载页面收到回调。
  • M04 部分通过:旧确认提交后出现「插件已发生变化,请刷新后重试。」提示,批准记录没有再次写入。但执行端更新确认本身已经合法批准新版 UI,无法构造「新版仍未批准」这一实机前置条件;该状态下迟到确认不得批准新版,仅有生产入口单测覆盖。

旧 main 对照和细项证据保存在上述目录,不复制内部账号或域名到 PR。

未执行的验证

  • 系统选择/另存为窗口 10 项:用户决定不测;工具无法稳定操作原生面板。独立 Electron 的 dialog 替身不能算原生操作通过。
  • 手机真实 UI、登录配对与完整 device-link 界面链:未实测。已有 controller/parser/Sheet/事务测试;没有本轮 Metro 或设备 build label。
  • 实机等待超过 330 秒、30 分钟硬上限及取消后的迟到选择:未实测。假时钟覆盖,真实等待仅覆盖约 101 秒;迟到文件不落盘/不签票有生产入口测试。
  • Windows 实机和全部手机 Light/Dark 目检未完成。
  • OIDC 未拿到独立签发回执,不能据此宣称签发链已验收。
  • C13 换账号在本轮受阻,之前轮次通过;本轮未重新验证通过。
  • SSH 主机未测。
  • 最新 tester 第 4 项的来源说明仅核对代码,未抓包;Auto 进入审阅和执行结果有运行证据。
  • Server 仓已完成契约核对,结论见下文;本轮未做 Server 生产部署与端到端发布验收,配套 Server PR [Maker] 发布过程中无法与 Maker 助手(塔拉拉)对话 #1146 已创建,尚不代表已部署。

风险

风险分类

  • 无已知风险
  • SQLite / migration
  • system prompt
  • 协议兼容
  • 权限 / 安全 / 用户数据
  • 存量插件兼容(批准状态 / 指纹 / manifest 校验 / 安装布局 / 包格式)
  • 原生层 / fingerprint / OTA
  • 跨平台差异

插件基座改动(需白名单放行人明确 Approve)

  1. Manifest v3 顶层 UI 契约、CSP/路径校验、工具 model/app 可见性;协议包、Desktop、作者手册同步。
  2. Receipt 可选 uiCapabilityApproved、安装/更新 facts 与扩权比较、远程同账号确认版本协商。无 schema bump、数据库或批准迁移。
  3. 宿主内虚拟 MCP、main.js 页面调用凭据、撤销与账号/实例/版本校验;页面不能调用 model-only 工具。
  4. pick 文件导入、调用续命/取消;Library 流式下载、文件上传、媒体/Library 的卡片只读地址与附件授权链。
  5. tool-progress 可选数值、标准 notifications/progress;草案 ui/download-file。
  6. 安装确认/详情/提示条的页面和 app 工具事实;手机/远程管理的增量事务以及本机文件降级。
  7. 作者工具打包版本下限与内置 Skill bundle 26;不恢复 main 已移除的 Harness 能力或批准字段。

存量兼容

  • 分享安装和分享替换保留原 prompt 的权限协商属性,安装确认不会新增页面批准;未批准页面在安装后仍须通过正常页面确认入口授权。F01 已用真实 RemotePluginManagement、分享安装入口、包落位/receipt 和页面批准入口复现并回归。

  • 已安装插件的读取、批准记录、启动重新校验、历史市场 Release 详情、安装和升级比较统一容忍畸形 mcpApps:保留原值作惰性数据,不读取页面、不授予页面能力、不显示页面待确认条;原工具、启用状态和原批准事实继续有效,不要求重装或重新确认。

  • 本地新安装、打包和本地分享仍严格校验;历史市场包的容忍标记只由 main 的市场交付路径传递,解析缓存按来源隔离。其他非法字段仍拒绝。所有 UI 权限判断复用安全路径校验,越界路径不构成页面能力或升级基线。

  • rebase 后本地分享/替换确认与页面授权分别保留;旧分享确认协议不会自动追加页面批准。

影响与回滚

  • 存量插件影响:无。旧批准记录和原工具继续使用;历史未知 UI 声明缺确认时不读取页面文件。带旧 Harness 字段的 receipt 在新 main 格式下读写仍批准,旧字段不恢复、不迁移;相关生产读写测试通过。
  • 跨端:新控制端通过可选能力探测后用 approve-ui/defer-ui;旧 Host 缺能力时不发送新动作。旧控制端泛化确认不能追加 UI 批准。访客拒绝;迟到 owner/revision/fingerprint 确认失效,丢回执只查询。
  • 手机新增纯 JS 的工作区协议包依赖,用于共享声明校验;未新增原生配置或原生依赖。本轮相同环境下比较 main 的 mobile 依赖与当前依赖,iOS/Android fingerprint 均不变;不宣称已完成手机实机验收。
  • 完全访问:自定义 MCP 页面、插件页面及已有能力关口遵守本任务 bypass;安装/页面一次性授权以及用户选文件/另存为动作不会被代批。远程访客权限边界保留。
  • 取消调用不会物理关闭已打开的系统选择面板;逻辑请求立即结束,迟到选择丢弃,面板关闭前保持 BUSY。
  • 后端上传一期单件 64MiB、总量 128MiB;媒体导入、Library 导入继续各自既有配额。更大上传仍需另行流式传输能力。
  • 文件链接仅本机卡片可读;手机/远程占位,不代理跨设备文件流。标准页面不受影响。
  • 回滚:回退这组提交后旧 Host 仍可读取批准记录与顶层未知字段,工具返回文字;新页面、文件桥接入口不可用。Library/媒体仍使用原有存储与回收机制,不需要数据库回滚。

Server 配合

以下为 Server 仓 developer-2 的核对结论:

  • 此前核查确认合法的顶层扩展能原样上传、存储、下发;本轮最终采用 mcpApps.ui,Server 需按下面的新结构同步校验。
  • Server 按包里的 manifest.minCindyVersion 做兼容投影,使用自己仓内的 plugin-protocol 副本。
  • Server PR #1146 配合两项:同步 mcpApps.ui 校验和 HTML 存在性检查;审核界面增加 UI 摘要。本客户端 PR 不修改 Server,也不代表这些配合项已经部署。
  • defaultInstall 只是一个布尔值,不提供页面批准事实,最终批准由客户端决定。

最终采用下发方完全信任口径:服务端 defaultInstall 的首次安装、组织默认接管、同源静默更新与仍具默认资格的恢复,将页面能力随真实包批准静默授予,不另询问、不出待确认提示条。换源接管使用本次默认下发授权,不继承旧来源授权。旧 Host 缺页面事实时,依据当前默认资格、来源账本与有效 receipt,通过现有市场更新事务重新校验当前发布包后补齐;忙碌或下载校验失败继续按既有更新规则重试,不绕过校验直接改事实。普通市场手动安装、自定义市场、本地包、Forge 和失去默认资格后的扩权更新仍需确认;审核结果、展示 manifest 或 defaultInstall 以外的信号不能代批。

合并 / 上线顺序

Server PR #1146 先上线,客户端随后发版。PLUGIN_UI_MIN_CINDY_VERSION 已定为 0.1.122-beta,与 Server 新 PR 同值。本 PR 不代表 Server 配合项已经上线。

提交前检查

  • 已人工 review 完整净 diff 与迁移冲突;自动 review 因 CLI 兼容失败如上
  • 每个 commit 都带 DCO 签名,pnpm check:dco 通过(最终提交范围的复验结果见下方)
  • UI 改动已注明设计规范
  • 未提交凭证、令牌或授权文件;tmp 不提交
  • 已同步作者手册与 MCP Apps 文档
  • 已说明验证结果与未执行项

最终声明格式与作者入口

  • 顶层 mcpApps.ui.resources[] 使用作者的唯一 ui:// URI 与包内 file;tools 值原样投影标准 _meta.ui。URI 单独改名不扩权,新增资源/域名/app 工具仍确认;HTML 内容更新不扩权。
  • domain / permissions 校验与保留,不承诺一期生效;mcpApps 未知扩展保留、不授予。
  • 新独立作者指南 §4.23(SKILL / Forge 章号与关键词入口),无构建 JSON-RPC 和官方 SDK 两示例均经生产打包和独立 Electron 验证。能力全集文件和普通联网示例可按块裁剪。
  • ghost_forge_scaffold 四种模板均可叠加可选 withUi:true;不传时保留原模板行为。新选项可使用 0.1.122-beta 发布下限,原无 UI 模板版本规则不变。
  • 本轮增加的验证使用既有测试文件;模板矩阵走生成→打包→真实装入并执行生成的 main.js。新的手册示例检查进入现有 plugin-ui.verify.mjs 的独立 Electron tier。
  • Server 配合还需同步最终字段名、资源 URI 唯一/引用/路径/CSP 校验、未知扩展保留、资源改名的权限比较和审核 UI 摘要;配套 Server PR #1146,不宣称已上线。

本轮新增回归的单文件实测(复用已有文件)

  • src/__tests__/manifest.test.ts:1.598s,通过。
  • src/main/cindy-brain/__tests__/ghostInstallConsent.test.ts:2.709s,通过。
  • src/main/cindy-brain/__tests__/forge.test.ts:26.462s,通过。
  • src/main/mcp-integrations/__tests__/ghostWorkdirGate.test.ts:16.512s,通过。
  • src/main/maker-host/__tests__/built-in-skills.test.ts:8.329s,通过。
  • src/main/mcp-apps/__tests__/pluginServer.test.ts:3.585s,通过。

本轮 forks 单独实测中,Forge 总墙钟 26.462s(Vitest collect 21.56s、测试执行 2.94s),ghostWorkdirGate 16.512s(collect 11.06s、执行 1.00s);超过 §3.2 的 10 秒说明线。主要时间在现有大入口的导入/转换,未新增 resetModules 或真实 sleep,已把新增矩阵并入既有文件、复用 fixture;没有为本批另做大型模块解耦。之前同一批三文件合跑 7.59s,环境负载有波动,以上如实保留本次独跑值,不用重跑挑选快值。Skill 8.329s,其余新增回归单文件低于 5s。

Rebase 后交付记录

最终基线 727afb1ad6,HEAD b1db854af7。16 个提交保留 DCO;rebase 前备份分支 backup/plugin-ui-bridge-before-main-20261029-final 仅保留本地,不推送。最终检查见上表。审批与分享的 tester 补测为 8/8 通过;本 PR 仍须插件基座白名单放行人明确 Approve,不能以自动检查通过代替。

2026-10-30 审查修复(834571f3c7)

本次追加提交处理 5 条评论(授权刷新两条重复,共 4 个问题)及 source-contract guard:

项目 是否本 PR 引入 处理与边界
页面 _meta 进入模型 是 剥除与卡片创建分开,覆盖 visibility-only、SSH 和无任务模型调用。未声明 UI 的旧工具业务 JSON 不改。
长文件名导入 是 固定前缀之后仅保留 22 字符,实际文件段不超过 64 字符,显示名仍完整。
无关刷新清空页面授权(两条重复) 是 只清已有 revoked 集合。包/版本、批准、实例、账号变更仍撤销,不扩大任务/工具授权范围。
业务 content 数组误当 MCP 结果 是,新页面桥接 标准 schema 校验成功才透传,否则完整 JSON 包装;标准结果及页面元数据不改。
市场安装顺序守卫 是,inspect 新增参数导致旧锚点失效 保留安全守卫并更新锚点,进一步断言捕获 → 检查 → 安装同意复核 → 写入租约。产品顺序未改。

生产入口回归先红后绿,证据在本地 tmp/e2e-plugin-ui/evidence/final-pr/review/。Desktop typecheck、4 文件 271 项定向测试、409 项 conformance(含 SDK / 原生 JSON-RPC / wheel Electron)、pnpm test:guard、test-hygiene、DCO(17 提交)、diff-check 均通过。

本批新增回归复用已有文件,单文件实测:pickedFiles 1.09s、pluginAppRegistry 1.05s、ghostWorkdirGate 4.96s、pluginServer 1.02s。分别经真实 LibraryVault 导入、真实刷新与内存授权、ghost_call 生产入口、真实 SDK 传输验证;测试注释记录最小失败输入和已有覆盖缺口。没有删弱断言或增加真实等待。

旧 HEAD 的 CI run 40903949139 已结束:Linux 4/4、Windows 3/4 单测分片通过;Windows 第四分片的 945 文件 / 15236 断言通过,但 Agent Island 的测试结束后残留定时器导致 2 个未捕获异常(getAvailableDisplays 读 undefined.length)。此实现、测试及 runner 配置与 main blob 相同,本机该文件 178 项通过;不是此前记录的 executor 两项 / auto-review 一项,本次没有复现那三项。按范围不改无关模块,不能宣称旧 CI 全绿;本提交触发的新 CI 需另看结果。

本地 codex review --uncommitted 仍因 CLI 与 gpt-6-astra 兼容性 HTTP 400 中断;已人工复核,并通过 PR 评论请求 Greptile / Codex 复审。PR 保持 draft、版本下限不变,不合并。

建议 tester 补测:本任务允许页面工具后切换语言或更新另一个插件,原工具不重复询问;升级当前插件或撤销页面能力后不得继续复用授权。未擅自拉起 tester。

第二轮复审修复:Library 路径长度(9d3f77db2e)

  • 宿主文件导入同时遵守单段 64、完整路径 256 的安全 ASCII 限制,按目录剩余长度裁剪生成名称;放不下 UUID 前缀及至少一位名称时,在打开选择器前返回 INVALID_REQUEST。
  • 公开能力全集 files 示例扣除时间戳前缀预算,中文原名保留作显示名;withUi 最小模板无该文件名拼接逻辑。手册仅补充一句路径限制。
  • 红/绿证据:212 字符目录经 importPickedFiles 和真实 LibraryVault 导入成功;213 字符目录经真实 pick 入口在选择器前拒绝;独立 Electron 通过真实页面拖放 200 字符中文文件名,三片写入后的内容与 SHA 一致。
  • 验证:Desktop typecheck、33 项定向测试、示例打包及五条 plugin UI verify、409 项 conformance 和配套 Electron 验证、test-hygiene、DCO、diff-check 全部通过。两个受影响单测文件独立运行分别为 1.17s 和 1.25s。
  • 本地 codex review --uncommitted 因现有 CLI 不支持所选模型而未完成;已人工复核最终 diff,并请求线上 Codex / Greptile 复审。建议 tester 在完整客户端补测长中文文件名拖入,关闭原报告第 02 项;此处自动验证为独立 Electron。

合入 main=449e757fa651a68e2a79e29c260220c94eae836d;补充手册动态内容小节与示例动态卡片

增加 v3 顶层 ui 页面资源与工具可见性,保留旧批准记录的兼容读取。

PLUGIN_UI_MIN_CINDY_VERSION 保持 9999.0.0,正式版本待定。

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
宿主内虚拟服务复用 main.js 处理函数、调用凭据、账号与版本撤销。
模型继续使用 ghost_call,不登记额外插件 MCP provider。

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
复用媒体和 Library 提供文件选择、流式下载与上传;按卡片授权只读引用。
绑定 pick 的续命与取消,迟到选择不得落盘或签票。

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
页面审批浮层、Auto/完全访问和任务内页面工具授权不改变模型授权语义。
修正高度反馈、滚轮链、历史卡消息与 Codex/Pi 的 App 工具取消。

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
复用 plugins 管理事务与确认 facts,绑定版本、身份和控制端能力。
远端本机文件卡明确降级,迟到确认显示已有失效提示。

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
同步作者手册、MCP Apps 限制和标准 SDK/JSON-RPC 文件及滚轮验证。
内置 Skill bundle 升至 24;页面最低客户端版本仍待定。

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
@fmfsaisai
fmfsaisai requested a review from a team as a code owner October 29, 2026 15:40
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-30T12:37:36.120686Z 9a7ad55 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@fmfsaisai
fmfsaisai marked this pull request as draft October 29, 2026 15:44

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: b1db854af7

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread apps/desktop/src/main/mcp-apps/runtime.ts Outdated
Comment thread apps/desktop/src/main/mcp-apps/pluginCards.ts Outdated
@greptile-apps

greptile-apps Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

RetriggerView in GreptileConfidence Score: 5/5

[High impact] 本轮修复未发现新的阻塞问题,从代码审查结果看可以合并。

Summary

本 PR 为插件增加标准 MCP Apps 页面、独立页面授权和文件桥接。本轮两处修复未发现新的可报告问题。

  • Plugin pages call existing tools through the host’s MCP Apps bridge.
  • Plugin pages get their own approval, separate from tool approval.
  • Plugin pages can import, use, upload, and save files through the host.
  • Page cards show approvals without shifting the chat and handle height changes.
  • Plugin authors get guides and examples for building MCP Apps pages.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A[远程请求 begin] --> B{执行端是否明确拒绝}
  B -->|是| C[清除操作并刷新快照]
  C --> D[等待用户显式重试]
  B -->|回执丢失| E[查询原操作]
  B -->|已创建| E
  E --> F[显示确认或最终结果]
Loading

Reviews (15) · Last reviewed commit: "fix(plugins): retain imports and recover..." · Reviewed by Greptile

Comment thread apps/desktop/src/main/cindy-brain/pickedFiles.ts Outdated
Comment thread apps/desktop/src/main/mcp-integrations/ghost.ts Outdated
Comment thread apps/desktop/src/main/mcp-apps/runtime.ts Outdated
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
@fmfsaisai

Copy link
Copy Markdown
Collaborator Author

@codex review

@greptileai 请复审最新提交 834571f3c70b023645c73295db19e6674858d0d8:5 条评论(授权刷新重复 2 条)已逐条回复并修复。页面元数据剥除不再依赖卡片创建;长文件名导入满足路径限制;无关刷新保留同任务同工具的页面授权,真实权限变化仍撤销;业务 content 数组经标准 schema 校验后决定透传或包装。市场安装 guard 只更新失效锚点并补强同意复核顺序,没有削弱守卫。

真实入口回归先红后绿;Desktop typecheck、271 项定向测试、409 项 conformance 含 Electron、完整 source-contract guard、test-hygiene、DCO、diff-check 均通过。PR 保持 draft。

原 CI 的 Linux 4/4、Windows 3/4 分片通过;Windows 第四分片全部断言通过,但未修改的 Agent Island 测试结束后有两次定时器未捕获异常,相关实现/测试/runner 与 main 一致。本次没有修改该无关模块,也不宣称旧 CI 全绿。建议 tester 补测无关刷新前后的页面授权记忆。

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 834571f3c7

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread apps/desktop/src/main/cindy-brain/pickedFiles.ts Outdated
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
@fmfsaisai

Copy link
Copy Markdown
Collaborator Author

@codex review

@greptileai 请复审最新提交 9d3f77db2e:为 Library 导入同时预留单段和完整路径预算,空间不足时在打开选择器前返回明确错误;公开能力全集示例扣除时间戳前缀长度,保留中文原始显示名。

已记录真实入口修复前失败、修复后通过证据:212 字符目录导入成功;213 字符目录不打开选择器;独立 Electron 中 200 字符中文文件名经实际拖放、三片写入真实 Library,落盘字节及 SHA 均一致。Desktop typecheck、33 项定向测试、示例 pack/verify、409 项 conformance 及 Electron 验证、test-hygiene、DCO、diff-check 通过。PR 保持 draft。

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Keep them coming!

Reviewed commit: 9d3f77db2e

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
@fmfsaisai
fmfsaisai marked this pull request as ready for review October 30, 2026 03:10
Comment thread apps/desktop/src/main/cindy-brain/librarySlot.ts Outdated
Comment thread apps/desktop/src/main/cindy-brain/pickedFiles.ts Outdated
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
@fmfsaisai

Copy link
Copy Markdown
Collaborator Author

@codex review
@greptileai

已普通推送 DCO 提交 20148e49c0ee81aef183a9c9fd4ae773a764fa08,请复审本轮四项修复:页面 HTML 共用 4 MiB 上限;通用安装检查 UI 资源普通文件;宿主 Library 导入复用 staging.release 的互斥链;多选失败返回已成功文件引用和首个失败项。

四条新意见已逐条回复并 resolve。崩溃残片沿用既有保留边界,两条相关意见按已裁决范围回复后 resolve,未新增自动删除。白名单 Approve 线程 4420103976 继续保留。

61f8768 的 client-ci 41009130402(13 jobs)与 CodeQL 41009127349(7 jobs)全部通过,无重跑。新提交本地 Desktop typecheck、相关七文件定向测试(617 项;补完安装目录/链接和撤权用例后,受影响三文件再跑 355 项)、test:guard、check:test-hygiene、check:dco、diff --check 均通过。四项都有修复前失败证据;完整日志位于 tmp/e2e-plugin-ui/evidence/final-pr/61f-watch/。本地 codex review 因现有 CLI 模型配置不受支持(model_not_found)未完成,已人工复核整体 diff,未把它计作通过。

新一轮 CI 和复审已请求,不等待运行结束。

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 20148e49c0

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread apps/desktop/src/main/cindy-brain/GhostManager.ts Outdated
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
@fmfsaisai

Copy link
Copy Markdown
Collaborator Author

@codex review
@greptileai

已普通推送 DCO 提交 ccb652bbed5d2387e134c7356bf6e5aa1b52f128。本轮更正历史包的兼容边界:市场/默认下发/分享/启动读取遇到无效 UI 资源,只禁用 UI,保留普通插件与原始清单;Forge/本地新包仍严格校验。同时处理 #4420969498,统一 4 MiB 校验。

兼容线程 4420763926 已补充说明并保持 resolve;新体积意见 4420969498 已回复并 resolve。白名单 Approve 4420103976 继续保留。

真实安装、更新、重启、分享及 Forge 回归有修复前失败证据;相关 7 文件 583 项通过,最后 Forge/兼容 2 文件 124 项通过。Desktop typecheck、test:guard、check:test-hygiene、check:dev-docs、check:dco、diff --check 通过。日志:tmp/e2e-plugin-ui/evidence/final-pr/stored-ui-compat/。本地 codex review 仍因 CLI model_not_found 未完成,已人工复核。新一轮 CI 与复审不等待。

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: ccb652bbed

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread apps/desktop/src/main/cindy-brain/pickedFiles.ts
Comment thread apps/desktop/src/main/cindy-brain/GhostManager.ts
Comment thread apps/desktop/src/main/cindy-brain/forge.ts
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
@fmfsaisai

Copy link
Copy Markdown
Collaborator Author

@codex review
@greptileai

请复审最新 HEAD 3f4c79b。本轮修复 af6529c:已安装缺页插件的分享/导出沿用 stored-release;新上传提审仍严格校验并返回具体原因;页面不可用时仍按原批准声明过滤模型结果的根 _meta。已 merge origin/main 08c0a10,保留市场存量语义及上游默认下发退订修复。12 个定向测试文件 1297 项、Desktop typecheck、guard、test-hygiene、DCO 及生成清单检查通过。白名单 Approve 线程继续保留待合并前确认。

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 3f4c79b62b

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread apps/desktop/src/main/mcp-integrations/plugin-app-registry.ts
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
@fmfsaisai

Copy link
Copy Markdown
Collaborator Author

@codex review
@greptileai

请复审最新 HEAD 1178e4e:插件页面连接新增规范化的安装目录身份;目录迁移后撤销旧 View/transport,拒绝从旧路径读取,新连接读取新目录。真实入口回归先失败后通过;28 个定向文件 576 项、Desktop typecheck、guard、test-hygiene、DCO、diff 检查通过。白名单 Approve 4420103976 继续保留待确认。

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. 🚀

Reviewed commit: 1178e4e23c

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
@fmfsaisai

Copy link
Copy Markdown
Collaborator Author

@codex review @greptileai 请复审 db66539。本轮合入 main=449e757fa6,生成命令解决 design-inventory 冲突;补充 §4.23 动态内容、凭证与可信 HTML 边界,以及可离线运行的动态内容卡片。真实 Electron 页面交互、浅深色与窄宽布局、打包、conformance、类型检查和各项门禁均已通过。

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: db6653939c

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread packages/maker-shared/src/mcpAppController.ts Outdated
Comment thread apps/desktop/src/main/cindy-brain/pickedFiles.ts Outdated
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
@fmfsaisai

Copy link
Copy Markdown
Collaborator Author

已普通推送 c479e97e66:包含 25ade3a574 的连续内容高度更新和并发媒体寄存配额修复,并合入 origin/main=17771cf87a4c90c31f5284f86c238f897d0a4744。两条线程已分别中文回复并 resolve;合并后定向测试14文件1646项、Desktop/Mobile typecheck、maker-shared build、guard、test-hygiene、DCO、diff检查通过。

@codex review
@greptileai 请复审最新 HEAD。

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c479e97e66

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread apps/desktop/src/main/cindy-brain/pickSlot.ts Outdated
Comment thread apps/desktop/src/renderer/components/new-chat/RemotePluginUiEnablePrompt.tsx Outdated
Signed-off-by: fmfsaisai <fmfsaisai@gmail.com>
@fmfsaisai

Copy link
Copy Markdown
Collaborator Author

已在 9a7ad55 统一修复本轮两条意见(已导入文件出票失败后的结果、远程页面 begin 明确拒绝后的恢复)。相关 154 用例、Desktop typecheck、guard、test-hygiene、DCO、diff 和本轮浅深色 UI 检查通过。原 c479e97 的 client-ci 13 个 job、CodeQL 7 项全部首跑通过,无重跑。

@codex review
@greptileai 请复审。

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 9a7ad55cb2

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

Comment thread apps/desktop/src/main/mcp-apps/host.ts
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