Repository navigation
Conversation
|
@Birfy — verdict request for this tip, once:
At that exact tip: 18 checks = 15 success + 2 skipped + 1 failure — the only red is Red-first evidence in the body: the two One disclosure already in the body: this sandbox has no |
|
FlyBot 2.0 audit (2026-11-25), read-only. This PR has no 2.0 landing point, so it was not repackaged; it stays open as the v1.0 record. Nothing was closed, retargeted or merged — the owner decides. It changes Evidence: |
|
基于已退役布局关闭(关闭原因,非验收结论)
|
|
基于已退役布局关闭(关闭原因,非验收结论)
|
Fixes #3360
Owner: Dev-1
Reviewer: Birfy
Written-by: Dev-1
Bot: FlyBot Dev-1
What changed
The bench preflight had three states —
pass,missing-pnpm,missing-native-addon— and checked only pnpm and the native addon. APATHthat carries pnpm and node but no coreutils therefore passed the preflight, andcore/dev/bench.shdied a few steps later with the shell linebench.sh: 91: mkdir: not found, which reads as a bench bug instead of telling the contributor what to install.core/dev/bench-preflight.mjs: a fourth state,missing-tool, plusREQUIRED_TOOLS(mkdir,cat,grep,rm,sleep,setsid,tail— the commandsbench.shruns after the profile install) andfindCommand()/missingTools()that probe each name withaccessSync(..., X_OK)over the realPATH(no--versionprobe: not every BSD tool has one).problemLine()names the first missing tool and where it usually lives. On WindowsmissingTools()returns[], becausebench.shis a POSIX shell script and the shell cases already skip there.core/test/bench-preflight.test.js: the twobench.shrefusal cases (:80,:88) build a fixturePATHwithout coreutils, so they now assert the preflight's refusal instead of the shell crash; a new unit case pinsstate: 'missing-tool'together with the named tool, and a new e2e case asserts stderr matches/mkdir is not on PATH/. The install-failure case gets coreutils onPATH, so it still proves the half-built-profile rule.docs/subsystems/ds-bot-core.md(the preflight paragraph) and the mirrorspatches/ds-bot/files/dev/bench-preflight.mjs+patches/ds-bot/files/test/bench-preflight.test.js, rewritten bynode scripts/ds-bot-patches.mjs generate(dev files live underfiles/, not in a topic patch;topics.jsonuntouched).Red first, on base
bab1fe963b65913f5cd1021d30e6598a7f571627New tests run against the base source (
core/dev/bench-preflight.mjsatbab1fe96, tests at the tip),cd core && TZ=UTC node --test --test-name-pattern='missing-tool|names a missing tool' test/bench-preflight.test.js:Green at the tip: the same command
# tests 2 / # pass 2 / # fail 0; the whole filetest/bench-preflight.test.js# tests 9 / # pass 9 / # fail 0.Verification at the tip
Tip SHA:
0f02274152855d9c976d8bfc65e498cec895f557(tree21fbeae02c89ee66338199719e32911dcda6b39b); the pushed head is generated from that same tree by the push path.Ran:
TZ=UTC npm run verify→ exit 0: 6107 tests, 0 failures — core3464/3464/0, plane25/25/0, social780/780/0, tree157/157/0, timeline178/178/0, workflow544/544/0, project153/153/0,.github+policy735/735/0, interop37/37/0, live-e2e34/34/0; plugin lint 0 errors;build-client --checkOK;ds-bot-patches check+canonicalok.ARCH_DOCS_BASE=bab1fe963b65913f5cd1021d30e6598a7f571627 npm run arch-docs→OK (5 changed file(s)).Not run: the bench smoke run against a real harness (it needs a machine-wide profile install and is out of scope here); no live-model test.
No user-facing changelog fragment: this changes a developer preflight's text and state, not a user-visible behaviour; the docs line in
docs/subsystems/ds-bot-core.mdis the discoverable record.No UI face: the change is terminal text, not a screen.
Checkpoint
{ "pr": 3362, "claim": "Dev-1", "issue": 3360, "summary": "The bench preflight passed whenever pnpm and the native addon were present, so a stripped PATH without coreutils died later at bench.sh: 91 with 'mkdir: not found'. It now has a fourth state, missing-tool, which probes the commands bench.sh needs after the profile install with accessSync(X_OK) and names the first one missing; bench.sh refuses before it writes the profile. Tests pin the state and the named tool, and the two bench.sh cases assert the refusal instead of the shell crash.", "files": [ "core/dev/bench-preflight.mjs", "core/test/bench-preflight.test.js", "docs/subsystems/ds-bot-core.md", "patches/ds-bot/files/dev/bench-preflight.mjs", "patches/ds-bot/files/test/bench-preflight.test.js" ], "checks": { "ran": "red on base: 2 tests 0 pass 2 fail (expected 'missing-tool' vs actual 'pass'; e2e actual bench.sh:91 mkdir: not found vs /mkdir is not on PATH/); green at tip: 2/2/0 and bench-preflight.test.js 9/9/0; TZ=UTC npm run verify exit 0 (6107 tests, 0 failures); arch-docs OK (5); patches check+canonical ok; build-client --check OK", "result": "green", "at": "6076353eb3576ebf48adfab74760895f5727fae6" }, "next": "none — ready for review" }