Repository navigation
Conversation
|
🦞👀 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 real behavior proof before merge. What this changesThis PR forwards invocation cancellation through hidden native spawn startup into initial worktree source acquisition. Example: A hidden sessions_spawn with worktree=true inherits a registered repository whose checkout lease is held, then the user presses Stop.
Review scores
ProductKind: Bug fix · Worth it: Yes · Fix scope: Complete Merge readiness⛔ Blocked before merge - 1 item remains Keep this PR open: it narrowly repairs a current cancellation gap, and no introduced correctness defect was found; the overlapping maintainer PR is not yet ready to supersede it. Priority: P2 Before merge
FindingsNone. Tests
Agent review detailsHow this fits togetherThe sessions_spawn tool prepares a native child through initial session creation, which asks the shared worktree owner for source access before committing child intent. flowchart TD
A[Invocation cancellation] --> B[sessions_spawn tool]
B --> C[Native spawn startup]
C --> D[Initial session preparation]
D --> E[Worktree preparation]
E --> F[Project checkout lease]
D --> G[Accepted child lifecycle]
Technical reviewBest possible solution: Carry the composed invocation signal only into existing initial worktree preparation, preserve accepted-child ownership, and consolidate the equivalent fixes when one is ready to land. Do we have a high-confidence way to reproduce the issue? The maintainer report gives a real held-lease reproduction, and current main visibly drops the signal before an otherwise cancellable acquisition; this read-only review ran no target code. Is this the best way to solve the issue? The diff is the smallest complete production repair: it reconnects existing cancellation owners without changing wait budgets, persisted intent, or accepted-child execution. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against bb92103e5698. Provenance checked
TestingProof path: in-process harness. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceSource +6. Total +6 across 4 files. Added test files: 0. View PR surface stats
Root-cause clusterRelationship: Members:
Proposal only: this assessment does not dispatch repair, suppress jobs, mutate sibling items, close, or merge anything. LabelsLabel changes:
Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed October 26, 2026, 3:37 AM ET / 07:37 UTC. |
|
Closing as a duplicate of #184345, which is already merged. That change forwards cancellation through initial native child preparation and includes regression coverage for source contention and child execution after startup. Thanks for the contribution. |
Fixes #184320.
When a hidden native
sessions_spawnwaits for an inherited registered repository, Stop currently closes the invocation's authority guard but leaves source acquisition waiting. Forward the already composed invocation/configured signal through native startup toprepareSessionWorktreeCreation, which already owns cancellable source acquisition.The optional signal is private startup context. It is consumed by initial preparation and is not added to model arguments, persisted pending-worktree data, child launch requests, or registry records. Existing authority guards and accepted-child lifecycle ownership remain in place. This is independent of #184272 / #184304 (source-wait budget) and #184121 (shared-fetch recovery).
Validation:
7e392e1d4440, all four signal combinations lose cancellation and remain pending after abort until release. With this patch, invocation-only, configured-only, and both composed-signal cancellation cases settle by the 25 ms observation while the source remains held, with zero child writes or launches and no late write after release.Draft / remaining proof: This local evidence uses dependency substitutes; it is not the reporter's real SQLite lease regression, an isolated Gateway Stop run, or proof of an accepted child's background execution. Those runtime checks, the focused repository suites, and type-aware lint/typecheck remain outstanding. No repository tests were added or modified and no build was run.
The issue discussion and related PR discussions/states were checked before publication; no competing fix for this initial hidden-spawn signal gap was found at that time.
Subsequent overlap (October 26): Maintainer PR #184345 was opened at 07:23:31 UTC, 49 seconds after this PR (07:22:42 UTC). Its production signal forwarding is equivalent and it includes real-contention and accepted-child regression coverage. I read its full body, diff, and both current comments and verified that it remains open, unmerged. Its latest review reports no code findings and is ready for maintainer review; this draft still has the validation gaps above. These are overlapping candidates for the same fix and should be consolidated before landing.