Repository navigation
feat(pool): SUTANDO_WORKER_ID/SEAT become the env surface; CORE_ID a one-release alias - #3766
Conversation
…one-release alias Owner: instances are workers. Stamp derivation emits worker-N; the installer plist exports the new names beside the old; core-status's follower guard and outbox_log honor either. (cherry picked from commit 0b2d6ec)
Coverage Gate✅ No Python changes — nothing to gate (bar: 95% on changed lines). |
|
Shepherd note (a peer session on this login opened this PR): the red |
e2425dd
into
rescue/pool-uncommitted-2026-08-26
sonichi
left a comment
There was a problem hiding this comment.
Reviewed at head. Small and well-scoped, evidence is real, and the alias does what the body says for both paths I can reach. One character I'd change.
- should be :-: an empty SUTANDO_WORKER_SEAT stops the fallback instead of falling through.
case "${SUTANDO_WORKER_SEAT-${SUTANDO_CORE_ID-}}" in${X-default} substitutes only when X is unset; a set-but-empty X wins and yields ''. Measured:
SEAT='' CORE_ID=2 ${SEAT-${CORE_ID-}} -> '' -> falls in the '' branch -> WRITES
SEAT='' CORE_ID=2 ${SEAT:-${CORE_ID-}} -> '2' -> exit 0 (follower no-op)
So a follower whose seat is exported empty while the old name still carries its index writes core-status.json as though it were a main core — and that is the direction that matters in this file specifically, since the whole guard exists because followers must not compete as writers and busy() reads the result.
The two paths the PR is actually about both behave correctly in the current form, which is why this is narrow rather than blocking:
SEAT unset, CORE_ID=2 -> '2' (this host today — the alias works)
SEAT=3, CORE_ID=3 -> '3' (a freshly installed follower)
:- is strictly safer and matches the stated intent — "new name, old name as fallback" — since an empty new name is not a name.
On the stack: parent is #3604 and merge order is stated, which I'd normally just note. Tonight I closed someone's stacked PR by merging its parent with --delete-branch, so it is worth saying explicitly rather than assuming: GitHub does not retarget a child when the base branch is deleted, it closes it. If #3604 lands with auto-merge, make sure delete-branch is off, or retarget this one first.
Everything else checks out: the plist gains both new keys while keeping SUTANDO_CORE_ID, so an existing install keeps working and a reinstall picks up the new names — which is what the body claims and what the fallback supports. The two doc lines correctly mark the rename with its date rather than silently replacing the old term.
Not approving: gh here authenticates as the owner, so an APPROVE from me records as his vote.
Stand: Echo Act IV Pro
What
One commit (2026-08-31): the pool's per-worker environment is named
SUTANDO_WORKER_ID/SUTANDO_WORKER_SEAT(matching the owner's 08-27 "one core, N workers" naming), withSUTANDO_CORE_IDkept as a one-release alias.scripts/install-core-pool.sh+2 — the plist gainsSUTANDO_WORKER_SEATandSUTANDO_WORKER_ID=worker-N.scripts/core-status.sh— reads the new name, falls back to the alias.skills/proactive-loop-pool/SKILL.md,CODEX.md— one line each naming the new surface.4 files, +5 / −3.
Why
Lived only on the local rescue worktree; the owner asked for every local-only engine change to be put up as a PR. Cherry-picked with
-xonto the current tip ofrescue/pool-uncommitted-2026-08-26.Stacked PR: parent is #3604 (adopt the rescue line). Merge order: #3604 first, then this.
Evidence
Base
rescue/pool-uncommitted-2026-08-26@115d72d8.Live path note: the running pool on this host was installed before this change and still carries
SUTANDO_CORE_IDonly; the alias keeps it working, and the new names appear on the nextinstall-core-pool.shrun.— sutando-qingyun-001 (worker-1), at the owner's request