Repository navigation
fix(bin): pin a Treehouse that supports the private pool root flag - #3
Conversation
The required "Behavior tests (Herdr)" lane fails on three spawn cases that all build a secondmate-shaped home: the launcher workspace E2E, the presentation multi-home E2E, and the workspace-per-home E2E. Each fails with error: treehouse get did not enter an isolated worktree within 60s (last seen '<the project>': it is the spawning project itself) The worktree-isolation assertion was right and caught a real failure to isolate. cfcd011 made a secondmate home's crewmate spawn acquire its worktree with `treehouse get --root <the home's private pool root>`, but Treehouse grew --root/TREEHOUSE_ROOT only in v2.2.0, and this lane pins v2.0.1. Measured against both binaries on the same scratch repository: v2.0.1: `treehouse get --root <root>` -> "unknown flag: --root" v2.3.0: enters <root>/.treehouse/<pool>/1/<project> Under v2.0.1 the acquire is rejected before any subshell opens, so the pane never leaves the project and fm-spawn.sh correctly refuses at the deadline. The assertion, its 60s window, and the test harness are all working as intended, so none of them is touched here; the fix supplies the capability the code depends on instead of relaxing the check that noticed it missing. This is not a regression that shipped past a gate. Workflow files were present in the tree when cfcd011 merged on 2026-09-17, but this repository had produced no workflow run, check run, or commit status of any kind at that point: its entire Actions history begins on 2026-09-20, and PR 1 merged with zero check runs and zero statuses on both its head and its merge commit. The run that surfaced this is the first CI run the repository has ever had, finding a latent incompatibility between what cfcd011 needs and what the CI environment pinned, on first contact. Nor was anything broken for real use. A machine whose installed Treehouse is v2.2.0 or newer acquires the private pool root correctly, before and after cfcd011; only the CI pin was behind. Move the pin to v2.3.0 - the version the local real-Herdr suite already exercises, which is what this installer's header has always said the pin tracks - with the checksums of the official v2.3.0 assets for all four supported platforms, and record in the header that the pin doubles as a capability floor that must never drop below v2.2.0. Note for follow-up, deliberately not fixed here: the same dependency is undeclared outside CI. bin/fm-bootstrap.sh probes `treehouse get --help` for --lease but not --root, so a home running a Treehouse older than v2.2.0 is never told to upgrade and instead loses 60 seconds per secondmate spawn to the same refusal.
How to read this changeThe worktree-isolation assertion was correct, and it was not touched. It refused because the pinned Treehouse genuinely could not hand a secondmate-owned spawn an isolated worktree: This is not a regression anyone shipped. cfcd011 merged on 2026-09-17, when this repository had never run CI — its pull request carries zero check runs and zero commit statuses. The workflow files were present in the tree, inherited from upstream, but nothing had ever executed them. CI's first run here was on 2026-09-20 and immediately found a latent incompatibility between that change and the CI environment's pin. That is CI working on first contact, not a break that slipped past a gate. Nothing was broken for real use, before or after. Secondmate-owned spawns have worked throughout on the machine this fleet runs on, which carries a newer Treehouse than CI pinned. Only the CI environment was behind. |
The required Herdr lane failed on this branch because the pinned Treehouse predated the --root flag that secondmate pool roots depend on, so no secondmate-owned spawn could reach an isolated worktree. d2d718f raises the pin to 2.3.0. This merge only brings that repair onto the branch; no file this branch owns is touched.
Intent
CI on this repository is red on the required "Behavior tests (Herdr)" lane, and it has been since the last merge to main. Every pull request raised from now on inherits that red and cannot go green, so nothing can land until it is repaired.
The captain's merge of the merge-guard change (pull request 2) is blocked behind exactly this, and its pipeline run was deliberately cancelled rather than allowed to repair unrelated code, so that work is parked waiting on this repair. The captain's standing instruction on that one is "merge it when CI is green"; this task is what makes green reachable.
This is repairing existing breakage, not building anything new.
What Changed
bin/fm-install-treehouse.shmoves the pinned Treehouse from v2.0.1 to v2.3.0, swapping the four per-platform archive SHA256 checksums (linux amd64/arm64, darwin amd64/arm64) and refreshing the version references in the usage header, download-ceiling note, archive-layout note, and--versioncomment.bin/fm-spawn.shacquires a secondmate home's worktree viatreehouse get --root(fromfm_treehouse_home_pool_rootinbin/fm-wake-lib.sh), and--root/TREEHOUSE_ROOTonly exists from v2.2.0 — below that the acquire fails withunknown flag: --rootand every secondmate spawn is refused by the worktree-isolation assertion. Records "never move this pin below v2.2.0".docs/architecture.mdgains one line in the secondmate-home section stating the v2.2.0--rootrequirement and the resulting refusal behavior when an older Treehouse is installed.Risk Assessment
✅ Low: The change is a single CI tool pin bump whose four checksums match the official v2.3.0 checksums.txt byte-for-byte, whose archive layout and
--versionstring satisfy the installer's own gates, and whose entire CLI surface used by the repo (get/--lease/--lease-holder/--root, return --force/--if-lease-*, prune --all --yes --root) plus the pool state layout are unchanged from the previous pin.Testing
I stood the repair up the way CI does: ran bin/fm-install-treehouse.sh for real (live download, checksum verify, version assertion) and put the resulting binary on PATH for the lane's treehouse-dependent behavior tests. The red lane's root cause reproduces exactly at the tool boundary — the previous pin v2.0.1 answers
treehouse get --rootwithunknown flag: --root, which is the acquire bin/fm-spawn.sh has issued for secondmate homes since the last merge — while the new pin performs a real leased acquire into the home-private pool root; v2.1.0 rejects and v2.2.0 accepts, confirming the v2.2.0 floor the comment and docs claim. All four pinned archives hash to the published release bytes, including the linux-amd64 asset the ubuntu lane actually installs. With the pinned binary, the workspace-per-home, presentation and autodetect real-Herdr scripts all completed green (43 assertions, exit 0), and the installer refuses a tampered checksum, a version mismatch, and an unsupported platform. One scenario could not be driven live: reproducing the whole lane failing end-to-end with the old pin, because the spawned pane inherits PATH from the machine's already-running herdr server, and shadowing that would mean restarting the user's server or replacing their global treehouse binary — out of bounds here. No UI surface is involved, so evidence is CLI transcripts rather than screenshots. Transient artifacts (temp install dirs, scratch pool roots under ~/.treehouse-homes created by the fixtures) were removed; the worktree is clean.bin/fm-install-treehouse.sh <tmpdir>— real GitHub download + SHA-256 +treehouse --version-> v2.3.0 (evidence 01-install-pinned-treehouse.txt)treehouse get --root) succeeds on the new pin and yields an isolated worktree under that roottreehouse get --lease --no-fetch --root <private-root>on the installed v2.3.0 leased .../.treehouse-homes/sm-abc123/.treehouse/proj-1b7ca5/1/proj, a real checkout of the scratch project (03-capabil…treehouse get --root ...->unknown flag: --root, exit 1 (03-capability-floor-root-flag.txt)unknown flag: --root; v2.2.0 -> flag accepted (08-root-flag-version-floor.txt)bin/fm-test-run.shon workspace-per-home (10 ok, exit 0), presentation e2e and autodetect smoke (exit 0, failed=0) with PATH pinned to the installed v2.3.0 (04-, 06- evidence files)Evidence: Pinned installer run: live download, checksum verify, install, version assertion
Source: Pinned installer run: live download, checksum verify, install, version assertion
fm-install-treehouse.sh: downloading treehouse-v2.3.0-darwin-arm64.tar.gz from https://github.com/kunchenguid/treehouse/releases/download/v2.3.0/treehouse-v2.3.0-darwin-arm64.tar.gz fm-install-treehouse.sh: installed treehouse v2.3.0 to /tmp/fm-pinbin.besxuT/treehouse v2.3.0Evidence: All four pinned archive checksums vs the real published release
Source: All four pinned archive checksums vs the real published release
linux-amd64 OK 94fd2b2c20c35aac1ddc2941317890ad82c9916f5ccecbac4a50cda783eed10f linux-arm64 OK 408589ba72b58d5e942071ed863a83fd96566cfd1e514945daa59defde528bbb darwin-arm64 OK 1cb09bcfa830b4eec5e54beeaa71589adb9c5d828573dda0f5150e2d80cf13d5 darwin-amd64 OK 349afcc13c2beb20d846eb560a11b30e1a5cab8e2dfb22988a36aa7f213b5881Evidence: Capability floor: old pin rejects `get --root`, new pin acquires into the private pool root
Source: Capability floor: old pin rejects
get --root, new pin acquires into the private pool root--- OLD pin v2.0.1 --- $ treehouse get --root $ROOT unknown flag: --root exit=1 --- NEW pin v2.3.0 --- 🌳 Leased worktree at .../.treehouse-homes/sm-abc123/.treehouse/proj-1b7ca5/1/proj exit=0Evidence: Which Treehouse version introduced --root (documented floor v2.2.0)
Source: Which Treehouse version introduced --root (documented floor v2.2.0)
v2.1.0: REJECTS --root (unknown flag: --root) v2.2.0: accepts --rootEvidence: workspace-per-home real-Herdr e2e with the installed pin (10/10 ok, exit 0)
Source: workspace-per-home real-Herdr e2e with the installed pin (10/10 ok, exit 0)
Evidence: presentation + autodetect real-Herdr tests with the installed pin (exit 0)
Source: presentation + autodetect real-Herdr tests with the installed pin (exit 0)
FM_TEST_SUMMARY total=2 failed=0 skipped_gate=0 duration_ms=998784Evidence: Installer refusal guards: bad checksum, version mismatch, unsupported platform
Source: Installer refusal guards: bad checksum, version mismatch, unsupported platform
checksum mismatch for treehouse-v2.3.0-darwin-arm64.tar.gz (expected deadbeef..., got 1cb09bcf...) exit=1 installed treehouse version is 'v2.3.0', expected exact pin v2.2.0 exit=1 unsupported platform Plan9-sparc; official Treehouse assets are linux/darwin amd64 and arm64Evidence: Old-pin lane re-drive (pane inherited the machine's treehouse, so this run does not reproduce the red lane)
Source: Old-pin lane re-drive (pane inherited the machine's treehouse, so this run does not reproduce the red lane)
Pipeline
Updates from git push no-mistakes
✅ **intent** - passed
✅ No issues found.
✅ **Rebase** - passed
✅ No issues found.
bin/fm-bootstrap.sh:928- bin/fm-bootstrap.sh:928treehouse_supports_leaseprobestreehouse get --helpfor--leaseonly, so a non-CI home running Treehouse <2.2.0 is never told to upgrade and loses the full 60s spawn window per secondmate crewmate spawn to the sameunknown flag: --rootrefusal this change fixes for CI. The author explicitly disclosed this as deliberately-deferred follow-up in the commit message, and the smallest honest remedy (extending the doctor capability probe to--root) goes beyond the stated intent of repairing the red CI lane, so no action is needed for this change.tests/fm-backend-herdr-workspace-per-home-e2e.test.sh:230- Running tests/fm-backend-herdr-workspace-per-home-e2e.test.sh standalone against a brand-new checkout fails in teardown with "REFUSED: cannot resolve the shared Treehouse project lock", because fm_treehouse_project_lock_path requires <FM_HOME>/state to exist and the test invokes fm-teardown.sh without FM_HOME (it falls back to FM_ROOT_OVERRIDE = the repo checkout, which has no state/ dir until something else creates it). In the CI lane an earlier family script creates it first, so the lane is unaffected; I created the dir and re-drove the scenario green. Flagged only as a standalone-run fragility.bin/fm-install-treehouse.sh <tmpdir>— real GitHub download + SHA-256 +treehouse --version-> v2.3.0 (evidence 01-install-pinned-treehouse.txt)treehouse get --root) succeeds on the new pin and yields an isolated worktree under that roottreehouse get --lease --no-fetch --root <private-root>on the installed v2.3.0 leased .../.treehouse-homes/sm-abc123/.treehouse/proj-1b7ca5/1/proj, a real checkout of the scratch project (03-capabil…treehouse get --root ...->unknown flag: --root, exit 1 (03-capability-floor-root-flag.txt)unknown flag: --root; v2.2.0 -> flag accepted (08-root-flag-version-floor.txt)bin/fm-test-run.shon workspace-per-home (10 ok, exit 0), presentation e2e and autodetect smoke (exit 0, failed=0) with PATH pinned to the installed v2.3.0 (04-, 06- evidence files)bin/fm-install-treehouse.sh <tmpdir>— real download, SHA-256 verify, install, version assertion (darwin-arm64)Downloaded and hashed all four pinned archives (linux-amd64, linux-arm64, darwin-arm64, darwin-amd64) from the real GitHub release and compared against the pins in the scripttreehouse get --root <private-root>andtreehouse get --lease --no-fetch --root <private-root>against a scratch git project, on v2.0.1, v2.1.0, v2.2.0 and the pinned v2.3.0bin/fm-test-run.sh tests/fm-backend-herdr-workspace-per-home-e2e.test.shwith PATH pinned to the installer-produced treehousebin/fm-test-run.sh tests/fm-backend-herdr-presentation-e2e.test.sh tests/fm-backend-autodetect-smoke.test.shwith the same pinned binaryInstaller guard drives on tampered copies in /tmp: wrong SHA-256, pin/version mismatch, unsupported uname platformRepo-wide check that no other script, workflow, or doc still references the 2.0.1 pindocs/configuration.md:524- The change documents a real capability floor (Treehouse v2.2.0 fortreehouse get --root) only in maintainer-architecture prose (docs/architecture.md:289) and in the CI installer's comment. Operator-facing surfaces do not carry it: docs/configuration.md's Toolchain section (the single owner of the tool list, which qualifies other floored tools with "v1.46.0 or newer" / "compatible") and docs/remote-secondmates.md:115's required remote tool set both list plaintreehousewith no version. Bootstrap's staleness probe also only teststreehouse get --helpfor--lease(bin/fm-bootstrap.sh:928), so a home or remote host on treehouse 2.0.x is reported healthy and then fails every secondmate crewmate spawn with an isolation refusal instead of an upgrade request. Closing this properly means extending the bootstrap probe to--rootand then pointing the toolchain docs at that floor — a code change, out of scope for a documentation-only phase, and documenting the floor in operator docs ahead of the probe would advertise a requirement the tool does not yet detect. Proposed as a follow-up.🔧 **Lint** - 1 issue found → no changes applied ✅
🔧 No changes applied.
✅ Re-checked - no issues remain.
✅ **Push** - passed
✅ No issues found.