fix: stabilize Treehouse spawn and teardown validation - #28
Open
ruby-dlee wants to merge 9 commits into
Open
Conversation
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.
Intent
Repair three stale Firstmate test suites so unattended fleet validation is green without network or access to the live Treehouse pool. The tests must use faithful local Treehouse lease fixtures that acquire, print, and return worktrees, and isolate Treehouse and checkout-refresh state so they pass when ~/.treehouse is empty or absent. Preserve production behavior except for the two explicitly authorized defects the fixtures exposed: canonicalize symlinked project paths before exact-root preflight, and make cleanup of an already-absent exact /tmp/fm- task root idempotent while still refusing wrong paths, symlinks, or traversal. Keep the existing symlink regression pin, add repeat-cleanup and wrong-path pins, and require all three suites plus changed-file fm-lint to pass.
What Changed
/tmp/fm-<id>task root idempotent while preserving unsafe-path refusals.Risk Assessment
✅ Low: The production changes are narrowly scoped and satisfy the stated path-canonicalization and idempotent-cleanup requirements while retaining strict rejection of unsafe paths; the revised fixtures isolate Treehouse and checkout-refresh state without introducing a substantiated defect.
Testing
Completed 1 recorded test check.
Pipeline
Updates from git push no-mistakes
✅ **intent** - passed
✅ No issues found.
✅ **Rebase** - passed
✅ No issues found.
✅ **Review** - passed
✅ No issues found.
command -v tmux >/dev/null || { echo "tmux is required for e2e tests" >&2; exit 1; }; tmux -V; rc=0; for t in tests/*.test.sh; do echo "== $t =="; bash "$t" || rc=1; done; uv run --directory tools/agent-fleet --locked pytest || rc=1; uv run --directory tools/agent-fleet --locked python -m compileall -q src || rc=1; exit "$rc"🔧 Fix: Isolate Treehouse fixtures from detached checkout state
1 error still open:
command -v tmux >/dev/null || { echo "tmux is required for e2e tests" >&2; exit 1; }; tmux -V; rc=0; for t in tests/*.test.sh; do echo "== $t =="; bash "$t" || rc=1; done; uv run --directory tools/agent-fleet --locked pytest || rc=1; uv run --directory tools/agent-fleet --locked python -m compileall -q src || rc=1; exit "$rc"🔧 Fix: Stabilize Treehouse fixtures and idempotent teardown cleanup
1 error still open:
command -v tmux >/dev/null || { echo "tmux is required for e2e tests" >&2; exit 1; }; tmux -V; rc=0; for t in tests/*.test.sh; do echo "== $t =="; bash "$t" || rc=1; done; uv run --directory tools/agent-fleet --locked pytest || rc=1; uv run --directory tools/agent-fleet --locked python -m compileall -q src || rc=1; exit "$rc"🔧 Fix: Stabilize Treehouse fixtures and idempotent teardown cleanup
1 error still open:
command -v tmux >/dev/null || { echo "tmux is required for e2e tests" >&2; exit 1; }; tmux -V; rc=0; for t in tests/*.test.sh; do echo "== $t =="; bash "$t" || rc=1; done; uv run --directory tools/agent-fleet --locked pytest || rc=1; uv run --directory tools/agent-fleet --locked python -m compileall -q src || rc=1; exit "$rc"⏭️ **Document** - skipped
⏭️ **Lint** - skipped
✅ **Push** - passed
✅ No issues found.