Repository navigation
Conversation
Separate serial worktree maintenance from preparation within the Git worker owner. Preserve shared capacity leases, ref serialization, cancellation, and shutdown settlement. Closes #147355 Co-authored-by: VACInc <[email protected]>
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. Reviewed September 13, 2026, 4:38 PM ET / 20:38 UTC (Revision 2). ClawSweeper reviewWhat this changesThe PR separates background workspace inspection and snapshots from foreground preparation into serial Git worker pools so new sessions can prepare their workspaces during slow maintenance. Merge readiness✅ Ready for maintainer review This remains a useful, focused fix for a bottleneck still present on current main. No blocking defects were found, and the updated build explanation resolves the previous review's sole follow-up. Priority: P1 Review scores
Verification
How this fits togetherManaged worktrees give sessions separate Git checkouts. The Git worker handles their sizing, file inventories, and snapshots, while the host service retains allocation leases, subprocess supervision, and ownership checks. flowchart TD
A[New session workspace request] --> B[Host allocation lease]
B --> C[Serial preparation worker]
D[Background cleanup and snapshots] --> E[Serial maintenance worker]
C --> F[Host Git execution and write guards]
E --> F
F --> G[Prepared checkout or maintenance result]
Before mergeNone. Agent review detailsSecurityNone. PR surfaceSource +12, Tests +98. Total +110 across 2 files. View PR surface stats
Review metrics
Root-cause clusterRelationship: Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. Technical reviewBest possible solution: Keep preparation responsive through the existing worker owner while preserving shared allocation leases, host-side write guards, and complete cancellation settlement. Do we have a high-confidence way to reproduce the issue? Yes: holding a pre-lease cleanup Git inventory and creating a worktree in another repository exposes the shared-worker bottleneck on current main. Source and the reported before/after service run support this path; this review did not execute it. Is this the best way to solve the issue? Yes: separating the two serial workloads inside the existing owner removes the demonstrated contention without replacing allocation, authorization, or Git-write safeguards. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 1c1affa936f6. LabelsLabel justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (1 earlier review cycle)
|
…1-prep * commit '912ae8d96e5964dfdcdf419b79613fb941cdf0a8': (350 commits) fix: keep workspace preparation responsive during cleanup (openclaw#147358) docs: alphabetize donors and sponsors and add Red Hat logo (openclaw#147302) fix(plugins): retain update authority through doctor effects (openclaw#144316) refactor(qa): share Multipass mount retry lifecycle (openclaw#147084) fix(memory): emit one JSON result for command failures (openclaw#147366) improve(plugins): speed up cold metadata loading (openclaw#147411) fix(sessions): avoid duplicate work after waited child replies (openclaw#147394) fix(agents): retain outstanding child results in parent context (openclaw#112623) test: preserve native workflow loader selection (openclaw#147403) fix: reduce repeated work while polling session pull requests (openclaw#147373) test(qa): preserve task cancellation across process replacement (openclaw#147382) fix: prevent sidebar refresh storms during session activity (openclaw#147400) refactor: simplify skills CLI formatting (openclaw#147368) fix: prevent Git checkout certificate failures behind egress proxy (openclaw#147410) fix(qa): stop live threads after their process leader exits (openclaw#147386) refactor(release): share agent turn retry lifecycle (openclaw#147076) fix(ui): keep uploaded images aligned with their prompts (openclaw#147389) fix(fs): guard skill reads and bound worker bundle staging (openclaw#147336) fix(ci): restore Linux service ownership fixtures (openclaw#147398) fix(plugins): preserve manifest permissions when building plugins (openclaw#147393) ...
…47358) Separate serial worktree maintenance from preparation within the Git worker owner. Preserve shared capacity leases, ref serialization, cancellation, and shutdown settlement. Closes openclaw#147355 Co-authored-by: roboclaw-bot <[email protected]> Co-authored-by: VACInc <[email protected]>
Closes #147355
What Problem This Solves
Fixes new worktree-backed sessions waiting behind unrelated background cleanup inspection.
User Impact
Foreground workspace preparation can finish while a slow cleanup inventory waits. Existing capacity, ownership, Git-write, cancellation, and shutdown safeguards remain in force. No configuration changes or migration are required.
Why This Change Was Made
Preparation and maintenance shared one serial Git worker. Keep both workloads serial, but give maintenance its own pool under the existing owner so a pre-lease cleanup scan cannot monopolize preparation. The extra worker uses the existing idle retirement and global pending-operation bound.
Removal that already holds the shared allocation lease still serializes with creation; this patch does not bypass that safeguard.
Evidence
pnpm buildpassed on the unchanged published head in a clean sequential run. The first attempt hit the compiler input-consistency guard during concurrent validation; the retry required no code changes or guard bypasses.Found while investigating chats that timed out with unfinished workspace setup. The exact historical timeout source remains uncertain; the blocking defect above is independently reproduced. Archived user sessions were not restored or modified by the repair.
Reported by @VACInc.