Repository navigation
test(e2e-browser): 飞书真机新增 core-sandbox 跑道,验证文件沙盒读写边界;Gemini 清空 GITHUB_SHA - #2563
Merged
Merged
Conversation
deepcoldy
requested review from
47seek,
LucasIcarus,
xiaoxueSunn and
xiongz-c
as code owners
October 29, 2026 23:40
deepcoldy
force-pushed
the
test/feishu-live-more-clis
branch
from
October 30, 2026 00:42
12665f8 to
7930106
Compare
deepcoldy
force-pushed
the
test/feishu-live-sandbox
branch
from
October 30, 2026 00:42
43209cd to
4208e80
Compare
deepcoldy
force-pushed
the
test/feishu-live-sandbox
branch
from
October 30, 2026 04:51
ec0cc7e to
83adf2a
Compare
…具剥掉 BOTMUX_* 变量、botmux send 发不出回复 Co-Authored-By: Claude Opus 5.5 <[email protected]>
mock LLM 新增 SANDBOX_PROBE:在沙盒会话的 shell 里跑固定检查,结果写进回复行逐字匹配; 测试同时核对宿主侧(金丝雀与密钥文件存在、越界写没落到宿主、工作目录写入落到宿主),检查不会空转; run-e2e.ts 给沙盒 Bot 用临时工作目录并 deny checkout 里的 bots 配置、登录态与 .env(沙盒把 checkout 只读挂入); workflow 安装 bubblewrap 并放开 Ubuntu 24.04 的非特权 user namespace 限制。 Co-Authored-By: Claude Opus 5.5 <[email protected]>
deepcoldy
force-pushed
the
test/feishu-live-sandbox
branch
from
October 30, 2026 05:58
83adf2a to
fd857a3
Compare
作者 rebase 后这些评审修复未包含在新基线中,重新应用: - 沙盒 Bot 无条件 mkdtemp 覆盖 workingDir(配置已存在也覆盖);workingDirs 整体替换为 [临时目录];defaultWorkingDir/defaultOncall.workingDir 存在时 重定向(四层 pin 都不能把会话钉回 checkout),复用 normalizeSandboxMode - 决策抽成纯函数 planSandboxBotConfig 并补 6 个变异级单测 - e2e afterAll 删宿主 canary;run-e2e cleanup 回收临时工作目录 Co-Authored-By: Claude Code <[email protected]>
Owner
Author
|
你好,自动评审补充说明(最终以维护者审阅为准): 你在 05:58 的 force-push 把分支 rebase 到最新 master 时,基线回到了最初的
另外你新增的 |
Owner
Author
|
收到,抱歉覆盖了你之前推的修复:rebase 时我用了本地的旧 head。已同步到 b3b5029 并核对过, |
This was referenced Oct 30, 2026
deepcoldy
pushed a commit
to uestcwangci/botmux
that referenced
this pull request
Oct 30, 2026
…ity-recovery-2473-final 五次同步 master(eb4311607..4896715,9 提交,含 deepcoldy#2563 真机沙盒跑道/deepcoldy#2547 沙盒 四修/deepcoldy#2577 herdr 认窗格/deepcoldy#2522 失效终端入口/deepcoldy#2558 白名单沙盒/deepcoldy#2552 会话控制 页精简/deepcoldy#2570 自动更新跳过/deepcoldy#2537 沙盒文档/deepcoldy#2580 Pi 恢复复制)。与本 PR 仅 worker-pool.ts / worker.ts 文件交集(deepcoldy#2547/deepcoldy#2522/deepcoldy#2558),git 自动合并干净、 无冲突标记;PR 关键接线(codexAppTurnFailureCode 四处、!turn.error 守卫、 pool 恢复落账、worker 签名 final 失败字段、Pi boot 20s 预算)逐处 grep 仍在 原位。合并树 build 过、codex 集成/容量/engine/deployment 243 项 vitest 绿、 容量 30 + Pi argv 1 项 bun 绿。 Co-Authored-By: Claude Code <[email protected]>
deepcoldy
pushed a commit
that referenced
this pull request
Oct 30, 2026
a247797 之后 master 进 #2547/#2577/#2580/#2563/#2540。3 文件 4 块冲突人工合成: - dashboard-ipc-server.ts:import 两边都留(本 PR 的 existsSync 与 #2540 的 sandbox-network-policy import),不重复 readFileSync。 - bot-defaults-page.tsx:保留 #2540 改的 export function SandboxSection,本 PR 的 CodexIsolatedConfigInfo 同存;networkUnsupported 调用逻辑已随 master 自动取三分支。 - i18n.ts(zh/en 真语义冲突): networkRequirements 合成双方意图「需 Linux 本地 PTY 后端 + 白名单隔离沙箱」; 删掉本 PR 仍引用的旧 networkUnsupported 单 key,采用 #2540 的 networkUnsupportedPlatform/Backend/Mode 三新 key,并把其中 oncall 文案 (Mode、networkPolicyBlocksChange)按本 PR 改名同步为白名单隔离/allowlist-isolation。 zh/en 各 3959 key 完全对称、无重复。 - 补落点回归 test/session-sandbox-drift-placement.test.ts(新增):钉 SandboxDriftChip 在会话表格 status 列与看板卡片头两个主视图都接上(#2552 拆分后 易在解冲突时丢失);SessionsTableBase 改 export 供断言。删任一落点双用例分别咬红。
This was referenced Oct 30, 2026
This was referenced Oct 30, 2026
|
@deepcoldy 合入 master 后的 Midscene E2E 失败:Feishu live Midscene 失败。 这次运行覆盖 e93ebf9…9b5544155(12 个提交),同批合入的还有 #2562 #2514 #2558 #2537 #2570 #2522 #2552 #2580 #2577 #2547 #2540,失败不一定由本 PR 引起。
|
This was referenced Oct 30, 2026
|
🚀 Released in v3.56.0 |
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.
改了什么
新增飞书真机跑道 core-sandbox:
ClaudeSandboxBot(Claude Code,sandbox: true)在真实私聊里跑一次沙盒探针。从会话自己的 shell 里确认:pid1/proc/1/comm与宿主不同(bwrap 自己的 PID namespace)homebots/stateoutsideworkdirsandbox-probe.ts:提问带SANDBOX_PROBE时,合成模型执行一条固定的botmux send,回复行里携带各项检查结果(ACK-<tag> SBX pid1=isolated home=HIDDEN …),用例按整行精确匹配。命令只由 mock 内置的片段拼成,插进去的只有 tag([A-Za-z0-9_-])和本进程已知的路径,不拼接任何消息原文。pid1=host home=READ … outside=WROTE),证明每项检查都能失败。scripts/run-e2e.ts:沙盒 Bot 的工作目录改用临时目录,不再退回 checkout,否则沙盒对 checkout 有读写权限。另外对沙盒 Bot 显式sandboxPaths.deny了 checkout 里的 bots 配置、storageState.json、.env,让探针的bots/state两项有确定的期望。bubblewrap,并设kernel.apparmor_restrict_unprivileged_userns=0(Ubuntu 24.04 默认限制非特权 user namespace)。附带:Gemini 清空
GITHUB_SHA#2562 合入时还没有这个提交。GitHub runner 上设了
GITHUB_SHA后,Gemini CLI 的 shell 工具会进入 strict 环境剥离,BOTMUX_*被剥掉,botmux send就发不出回复。表现是 live 运行 40974624555 里 Gemini 调到了 mock,但回复始终没有出现。本机复现过:GITHUB_SHA=abc123时 shell 里BOTMUX_PROBE=missing,置空后为present。修法是在mockCliEnv的 gemini 分支里加上GITHUB_SHA: ''。影响面
只动测试、mock 与 CI,不动
src/。沙盒易用性问题已另提 #2528–#2533。验证
bunx vitest run test/mock-sandbox-probe.test.ts test/mock-llm-server.test.ts test/midscene-suite.test.ts test/midscene-lanes.test.ts test/midscene-e2e-workflow.test.ts test/test-hygiene.test.ts通过。mock-sandbox-probe在宿主上执行探针命令,6 项检查都得到相反值。Sandbox hides home and harness secrets都是第一次就通过(130s / 84s)。🤖 Generated with Claude Code