跳到內容

0.57.1

本頁內容尚未翻譯。

Released 2026-11-04.

  • Reload every pi session after the update (/reload). The first pi session that loads 0.57.1 restarts an older sb server.
  • The Herdr reaper plugin in this package is 0.4.1. A Herdr that runs an older copy keeps working; update the plugin to get its new hint.

0.57.0 was tagged but never reached npm: its tests failed on Linux. 0.57.1 carries everything below, with those failures fixed.

A worker that ends no longer leaves its processes running. On 2026-11-03 a worker’s tests left detached node processes that ran for hours with their working folder in a worktree.

  • Owner marker. Every pi sets STRAW_BOSS_OWNER, and the processes it starts inherit it. A worker (a pi with PI_SUBAGENT_ID) checks in with the sb server, beats every 30 s, and says bye when it quits.
  • Reaping. When a worker ends (bye, its pid gone, or its pane closed), the sb server finds what it left: processes in its snapshot, processes carrying its marker, and orphans whose working folder is in its linked worktree. It sends SIGTERM, then SIGKILL 10 s later, and logs one procs-reaped line with counts.
  • Never touched. The Herdr server, pane shells and their foregrounds, sb servers, the intercom broker, every live worker and its tree, and other users’ processes. Each pid’s start time is checked again right before each signal. A folder where another live owner or pane works is skipped by the folder rule.
  • Removal guard. worktree_remove, git worktree remove and herdr worktree remove are refused while a process works in the checkout. The refusal lists pid, program, CPU, age and owner state (never a command line) and the command that stops them. An idle pane shell does not count. A check that cannot run refuses.
  • procs command. cli.mjs procs lists what the sb server knows; procs reap --owner <id> and procs reap --checkout <path> stop leftovers. --checkout accepts only a linked worktree or a removed folder that was a known worker’s root, and refuses /, a home folder, a main checkout and any parent of a checkout.
  • Reaper plugin 0.4.1. Its refusal now names procs reap --checkout.

Known limits (macOS): the environment of Apple’s own programs (sh, bash, sleep, perl) cannot be read, so the marker does not find them; the snapshot and folder rules do. A double-forked process in a worktree another pane also works in survives the reap; procs reap --checkout stops it. See docs/specs/2026-11-04-procs.md.

  • Tower and ally runs start on Linux. Herdr lists a pane’s process on Linux by name alone (no argv0, and pi’s process title rewrites its command line), so the sb server never found the run’s pi and every run crashed at start. A process named pi now counts when it is the only one in the pane’s foreground or its process-group leader, never one that names another run.
  • Program names. Node 24 renames its main thread MainThread, which Linux ps shows for every node process. Refusals and reap reports now name the real executable, read from /proc/<pid>/exe only where it is shown.
  • tsx on Node 22.22. The sb server loaded tsx through its CommonJS entry, from which tsImport cannot find its own ESM file on Node 22.22.x, so pi-intercom never loaded and Straw Link never started. It now uses tsx’s ESM entry, and a failed load names the Node version.
  • Pane balance after quit. With no Herdr server, Herdr’s CLI answers server_not_running; balance.mjs after-close now treats that as Herdr gone and stops at once instead of waiting 30 s (macOS and Windows).