Repository navigation
T-1245 T-1239④ Cry Bot InstaBox 云电脑:设置页钥匙、后端选择、快照 - #61
Merged
Merged
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…PI_KEY Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
台账任务
台账任务:T-1245
改了什么
改了什么
新增 钥匙目录项(环境变量来源显示为只读行)、三后端选择、快照路由/假服务/面板与确认流程、中英文文案;电脑面板只加两行挂载,配置路由净增 9 行,wire 保持 1000 行。实际改动文件与
git status --short --untracked-files=all一致:为什么
支持每个智能体的 磁盘快照,限制 admin/同源访问、拒绝跨智能体恢复/删除、全量调用使用
idempotent: true,恢复完成后调用ensureRunning(botId)开桌面。钥匙响应仅含{ configured, fromEnv },不含明文和尾号。⑤ 接线的确切签名:
**尚未独立闭环:**遵守原文件边界,未改
server/index.ts、server/config.ts、server/store.ts。①/⑤须注册路由,并在配置 schema、saveConfig 的 section 合并列表、加载/环境变量读取、全局 configStatus 及 config 广播接上 。隔离实测当前saveConfig({instabox:{apiKey:[REDACTED]会丢弃该字段,所以本分支不能宣称钥匙已可持久化;本任务路由已接收/校验保存与清除 patch,并拒绝覆盖INSTABOX_API_KEY。此前范围扩展询问未收到确认,保留原范围。存快照和恢复都在单个 HTTP 请求里同步等待:快照对象形状最多等待 ready 180 秒;操作单形状最多等待操作单 180 秒、按唯一名称发现快照 180 秒、再等待 ready 180 秒;恢复最多等待操作单 180 秒,随后同步等待ensureRunning。⑤ 接线时应让前端和反向代理超时覆盖这些等待。测试命令与结果摘要
docs/verification/README.md缺失;验证全部使用隔离 HTTP 假服务/临时数据目录,无真实 调用。pnpm exec vitest run <文件> --maxWorkers=1:20 个文件、242 项通过(去重计数),具体文件及命令见 verification.txt。快照路由 e2e 最终连续 3 次,各 11/11。node --experimental-strip-types <isolated browser capture script>:Chromium 隔离组件页面,三后端切换、存快照、取消/确认恢复、确认删除连续 3 轮通过;环境变量钥匙无编辑按钮。1280/390/360 宽及确认框无横向溢出。1280 截图、390 截图、环境变量只读截图。pnpm exec tsc -p tsconfig.server.json、pnpm exec tsc -p tsconfig.json、改动 TS/TSX 文件的pnpm exec oxlint --deny-warnings、行数门禁、git diff --check均通过。node scripts/generate-locale.mjs --check通过;pnpm exec vitest run src/lib/i18n.test.ts --maxWorkers=1为 38/39:activePackComplete写死要求 pt-br 覆盖全部英文键,新加的 20 键仅在用户授权的 en/zh 中,故此项未过;未修改其他语言或范围外测试。第 2 轮
改了什么
server/routes/instabox-snapshots.ts、server/routes/instabox-snapshots.e2e.test.ts、server/testing/fake-instabox-snapshots.tssrc/locales/en.json、src/locales/zh.json、src/locales/pt-br.jsondocs/tasks/T-1200/T-1245-instabox-settings/verification.txt、docs/tasks/T-1200/T-1245-instabox-settings/report.md为什么
创建快照现在兼容快照对象和生命周期操作单:操作单完成后按本次生成的唯一名称查找快照,再等待 ready;假服务默认返回操作单,并保留快照对象开关,两种形状均有测试。pt-br 补齐本轮新增的 20 个英文键,并同步删除未使用的
keys.instabox.configured。验证记录改为仓库相对路径。公开接口文档https://api.instabox.sh/v1/openapi.json当前将POST /v1/machines/{id}/snapshots的 201/202 响应描述为Snapshot;实现仍兼容任务约定的操作单返回。测试命令与结果摘要
pnpm exec vitest run server/routes/instabox-snapshots.e2e.test.ts --maxWorkers=1:12/12 通过;最终验收连续运行 3 次。pnpm exec vitest run src/lib/i18n.test.ts --maxWorkers=1:39/39 通过;node scripts/generate-locale.mjs --check通过。tsc -b、tsc -p tsconfig.server.json、改动文件oxlint --deny-warnings、行数门禁和git diff --check的结果已追加到verification.txt。未提交 git。第 3 轮
改了什么
将 纳入 27 项钥匙的保存、读回、末四位掩码和删除流程,补齐配置持久化、状态广播及前端状态转换;补充决策服务假响应,以及环境变量优先级、凭据隔离和末四位保留的同类测试覆盖。实际文件列表:
验收证据
审核、安全审查和测试结论见本 PR 检查状态及评论。
风险与回退
待补充风险;合并后可通过 revert 压缩提交回退。
🤖 Generated with Claude Code