Repository navigation
Description
What happened
pm-git-sync.service (user unit, 30s timer) failed every run from 2026-11-08 until fixed 2026-11-10 ~09:00 CST. The service itself was healthy and behaving exactly as designed — it refuses to pull unless ~/git/code is on a clean main. The clone was neither:
- A queue lane worked directly in the primary clone. ~/git/code sat on branch queue/13790-5954-deploy-smoke-fixture (checked out 2026-11-08 16:43 CST, one commit 9d7f54f, also pushed to origin under the same branch name) with uncommitted WIP edits across 9 tracked files (claimant, fleet-paperwork, mcpx; all stamped 2026-11-09 21:31:21) plus untracked files (incl. a whole nested checkout base-agg/). Because the sync was stalled, merged config had to be written into the live OpenCode config by hand during the 2026-11-10 deploy (PRs routes: workhorse-weighted Luna #xhigh seat switches to Terra #low #8162/routes: workhorse-weighted Gemini 3.8 Flash seat drops #high to #medium #8164).
- A stale lane worktree squatted main. ~/git/fleet/12652-main held the main branch checked out (same commit as ~/git/fleet/12652 and 12652-3939-quota-uninstrumented), so even after cleaning, git checkout main in the primary clone was refused. Its apparent dirt was stale-base drift (Nov 8 base), not unique work.
Fix applied (2026-11-10)
- All dirt preserved first: ~/git/code-dirt-rescue-2026-11-10/ on the laptop (tracked patch, two copies of every untracked file, 12652-main full diff + status, README). The opencode.jsonc edit was already byte-identical to origin/main; the remaining edits are stale-base versions of files that moved substantially on main since — recoverable from the rescue dir if any lane still needs them.
- Clone restored to clean main; stale worktree removed; sync restarted. Proof: one full cycle pulled 436 commits (1e46b89 → 68dda49), restarted pm-projector + pm-dispatch, exit 0; follow-up timer run: ok clean main, up to date. HEAD == origin/main == 68dda49; live config byte-identical to main.
Prevention gap (the ask)
Lane/worker setup must never check out a branch or edit files in the primary clone (~/git/code), and must not create worktrees that hold main. Options: lane launcher refuses to start when its working dir resolves to the primary clone; a periodic check that no registered worktree holds main; pm-git-sync could also page louder than a journal FAIL when stalled >1h. Acceptance: a lane attempting to work in ~/git/code is stopped or redirected to a worktree, and a main-holding worktree raises a visible alert within one sync cycle.
Acceptance criteria
- The prevention gap named in the body is closed: primary-clone dirt can no longer silently block the OpenCode claimant and pm-git-sync — it is prevented, or detected and surfaced loudly with the owner named.
- The mechanism is verified against a deliberately dirtied clone (or an equivalent drill) and the evidence is recorded on this issue.
Activity
developing-today commentedon Nov 10, 2026
CODE-2413
dezren39 commentedon Nov 14, 2026
🤖 Agent note · state
dezren39 commentedon Nov 14, 2026
Dirt cleared under Drew's order — full accounting (2026-11-14)
Drew's ruling (2026-11-14 02:52 CT, main chat): "commit or something" — the fleet was authorized to preserve the primary clone's foreign dirt and restore a clean main. This is the second occurrence of the #8170 pattern (first: 2026-11-08→10).
Preservation (before anything was touched)
~/git/primary-dirt-2026-11-14.patchon the laptop — 175,224 bytes, sha2561eb64b0e55295a65b051779dffb4c2a6b0a73160c2dc670930a5376015147746.~/git/primary-dirt-2026-11-14-untracked/(4 files: pm-stack/aggregator/playwright.config.ts, test/browser/mobile-work-view.spec.ts, test/latest-comments-9781.test.ts, test/program-prime-5082.test.ts). Nothing was discarded silently; the whole pre-reset state is recoverable from the patch + copies.What the dirt was (primary sat at 7535eba, 174 commits behind origin/main)
Restore + verification
28955acdf867df227cc36df0af63897fc417f711;git status= 0 lines, working tree clean.pm-git-sync: ok clean main, up to date at 28955acd..., Result=success, timer firing on its ~30s cadence. The aggregator deploy path (clean main → subtree-change redeploy) is unblocked.Closing note
Closing on the deploy-path criterion: the clone is clean, current, and syncing. Recorded for honesty: the prevention acceptance in this issue's body (a lane attempting to work in ~/git/code is stopped or redirected; a main-holding worktree raises a visible alert) is not implemented — this recurrence happened under the same conditions as the first. If that guard is still wanted, it deserves its own tracked issue rather than dying inside this close.
developing-today-fleet commentedon Nov 29, 2026
Builder's advocate recurrence evidence — 2026-11-29 04:16 CST
The primary-checkout prevention gap recorded at closure has recurred. The current
/home/user/git/codecheckout is onmain, 435 commits behindorigin/main, withpm-stack/opencode-claimant/poll.pyunmerged (UU) and unresolved conflict markers. Scheduled claimant fires repeatedly fail before queue discovery withIndentationErroratpoll.py:621/IndentationError: expected an indented block after 'try' statement; no task is claimed, bound, or launched.Session evidence from the same fleet window:
ses_e5dd96e7abcffeFMrVYq1HRMN1(03:10),ses_e5dd969e8b0ffeP3VqQS1VFmd2(03:15),ses_e5dd965533cffekLd0XjEyecLC(03:20),ses_e5dd960c0afffe12v04R4MyxBq(03:25),ses_e5dd95c2a89ffeOR1mjxP8Oo5s(03:30),ses_e5dd9579341ffeSVu7SqnO7va7(03:35),ses_e5dd952fca2ffeUrUWhyfBTTMA(03:40),ses_e5dd94e6bd5ffeV0xcjpkZ7p6z(03:45),ses_e5dd949dc42ffeihj5stYE1AFS(03:50),ses_e5dd94544ecffe8D7aoPQYj3BW(03:55), andses_e5dd93c1ce6fferD310ssvDl7q(04:05). The 04:00 claimant,ses_e5dd940b06affe4LldE54r0gFz, explicitly stopped retrying against the conflicted checkout. No checkout files were changed by this advocate.The issue was reopened because the recorded prevention acceptance was not implemented and this is a fresh recurrence. Acceptance remains the issue's guard: a claimant started from the primary clone is stopped or redirected before importing the conflicting worktree, while an attempted worktree holding
mainproduces a visible alert within one sync cycle. The conflicted checkout remains preserved; it needs a safe, separate disposition.[-]pm-git-sync stalled 2026-11-08→10: queue lanes worked directly in the primary clone and a stale worktree squatted the main branch[/-][+]fleet-stalling: primary clone dirt blocks OpenCode claimant and pm-git-sync[/+]2 remaining items
developing-today-fleet commentedon Nov 29, 2026
Evidence only — lane 0640-E (Felix), read-only inspection via fleet shell, 2026-11-29 ~13:35Z. No files changed.
The primary clone /home/user/git/code on amd-6 is again occupied as a lane worktree: currently on branch oc-code-08/atlas-5350-slice (up to date with its origin branch), 639 commits behind origin/main, with staged changes (.mcpx.json, one design doc) and unmerged UU entries in the working tree: .opencode/opencode.jsonc, doc/2026-11-01_design_id2039.md, doc/2026-11-01_design_id2290.md, doc/2026-11-23T06-50-00Z_architecture_pm_platform_cloudflare_core/...md (first 8 status lines; no MERGE_HEAD present, so the UU state came from a stash pop or interrupted checkout rather than a live merge).
This is the #8170 pattern recurring through a different door than the 04:16 CST poll.py incident: a queue lane working directly in the primary clone. This lane did not touch the tree — the branch is a live lane's workspace and its UU resolution is that lane's to finish. Recorded so the prevention-guard acceptance (stop or redirect a claimant/worker started from the primary clone; alert when a worktree holds main) has current evidence: the guard still does not exist, and the primary clone is still the path of least resistance for lane work.
developing-today-fleet commentedon Nov 29, 2026
Census 2026-11-29 (Felix):
developing-today-fleet commentedon Nov 29, 2026
Priority validation 2026-11-29 (Felix): priority/critical → priority/high — the critical band is reserved for main broken, security exposure, or repo-wide outage; this is a live, recurring fleet-stalling blockage on one seat's primary clone (important and time-sensitive), but GitHub main and the wider repo are not down.
developing-today-fleet commentedon Nov 29, 2026
Issue census — 2026-11-29
Gaps found: no
## Acceptance criteriasection (appended this pass, original body text unchanged).Strengths: detailed body with context a picker-up can start from; linked to its epic/programme via epic/* labels.
Actions taken: labels added this pass:
effort/m; appended## Acceptance criteria(original body text unchanged above it)Priority: priority/high retained live (lowered from critical by a parallel pass today; the body records the incident itself was fixed 2026-11-10 and the remaining ask is the prevention gap, so high fits).
pm-stack: guard claimant from primary clone (#8170)
developing-today-fleet commentedon Nov 29, 2026
Progress from Fleet lane oc-code-06 (queue task 26392): primary-clone startup is refused before task-code loading, and pm-git-sync now reports registered main-holding worktrees each cycle. Regression coverage passes (80 claimant tests and the pm-git-sync quarantine suite). PR: #16932. The implementation branch and queue claim are oc-code-06; commit identity reflects the checkout Git config.