Repository navigation
0.11.0 — worktree sandbox hardening + multi-session repo safety
Worktree sandbox hardening + multi-session repo safety
Several Pi sessions (or parallel subagents) on one repository no longer clobber each other. Ported from oh-my-pi + Claude Code at ponytail scale — zero new dependencies, zero new settings.
subagent module
- Per-repo lock —
worktree add/removeandgit apply --3wayserialize per repo root; parallel children can no longer race git's no-waiterindex.lock. - CoW backend (macOS) —
sandbox:"worktree"now clones your working tree viaclonefile(2): near-zero time and disk, and the copy is your working tree — uncommitted changes,node_modules, and.envcome along for free. Self-copy-safe construction (per top-level entry into a sibling staging dir, atomic rename); falls back to a detached git worktree anywhere else. - Baseline carry — on the worktree fallback, the parent's uncommitted state is captured as pure reads (no
git add/stash) and seeded into the sandbox, so children never work a stale tree andmerge:"3way"patches land cleanly. - Owner markers + GC — crashed runs' sandboxes are swept automatically on session start (dead-pid detection, registration-aware removal);
/subagent worktrees [clean]lists or forces the sweep. .worktreeinclude— gitignore-style list of gitignored files (env, configs) copied into fresh worktrees.- Sandboxes auto-gitignore themselves — no more
?? .pi-worktrees/ingit status.
repair module (always-on, deterministic)
- Conflict footer — full-file reads surface unresolved merge-conflict blocks automatically.
- Write freshness guard — a
writeto a file another session changed since you last read it fails before writing with a re-read-first error; no more blind clobbering.apply_patch/str_replace_editorparticipate via arefreshMtimeseam.
Docs
README now documents every module in the bundle (subagent, repair, steering, zai, a2a, todo, rules, gh, attachments, cron, permission were missing).
Verified live: baseline carry through a real sandboxed child, GC sweep in a fresh headless Pi session, herdr-pane load, both repair guards through real wrapped tools, and a concurrent two-child merge:"3way" race — both patches landed, no conflicts, no lock leftovers. 23 new tests; suite at 2639 green.
Also fixes two CI-only test failures that pre-dated this release (TZ-sensitive cron expectation; a11y test that needs real Chrome).