GeezerVison is showing github.com — feat(queue): Muse->opencode push — claim-by-id transfer verb (--from-session), one-call send with notes + worktree, reason-gated platform limitation (#8210) by dezren39 · Pull Request #8223 · developing-today/code
Conversation
dezren39
commented
Nov 10, 2026
•
edited by blacksmith-sh
Bot
Loading
Uh oh!
There was an error while loading. Please reload this page.
Closes #8210.
Drew's asks: a Muse session can send a task it holds to opencode — automatically claimed, with the Muse agent's notes and the worktree provided — and a verb to claim a specific task, session-to-session, "passed on without needing any stops". Plus: a task may be limited to muse or opencode only with a good recorded reason.
Broker (fleet-queue, turso_queue.rs + client.rs)
- Claim-by-id transfer:
claim --task <id> --from-session <ses> moves a live claim holder→claimer in ONE conditional UPDATE (status stays claimed, attempts untouched, holder worker re-checked in the WHERE). --session-id on the same claim binds the claiming session atomically (progress + lane ledger). The claimed event records transfer: true, from_session, the new session_id, previous_worker/previous_lane_id, and the fix(queue): single-session by default — launch-on-handoff, lane works, inline triage (reverses #8097 Rule 3) #8187 marks. Guards (all checked before any mutation — a refused transfer leaves the original claim untouched): status must be claimed under a live lease; from_session must match a holder session mark (latest claimed event's session, bound progress.session_id, or a holder-checkpointed progress.from_session); a row bound to a third session refuses; wait-parks/terminal rows are not transfer sources.
- Lane flip direct→opencode:
verb_lane's existing-row path could only flip opencode→direct; a claimed task's default direct row can now flip to opencode with --opencode-reason (unbound rows only), reason recorded, lane_assigned event with reassignment: true.
- Platform limitation (Drew: limited "but better be good reason"): lane ledger gains
platform_limit / platform_limit_reason (fresh schema + additive migration). Set only via lane --limit-platform muse|openchamber --limit-reason "<why>" (refused without a reason; --clear-platform-limit removes it). A stored limitation with no reason is invalid — the transfer claim clears it and records platform_limit_cleared_invalid on the claimed event instead of enforcing it. A valid limitation binds transfers: the refusal names the limitation and its reason; unlimited tasks never refuse on platform grounds. The fix(queue): single-session by default — launch-on-handoff, lane works, inline triage (reverses #8097 Rule 3) #8187 oracle test platform_is_a_mark_not_a_lane_input_8187 was narrowed to its actual invariant (verb_lane never reads the tasks.platform mark column) with the reason recorded in the test.
Send tool (pm-stack/opencode-claimant/send_to_opencode.py, new)
One call: verifies the sender holds the claim + live hard-stop labels, resolves/creates the worktree (never the primary), writes the sender's notes into it (SEND_NOTES.md), records the opencode assignment with the sender's --reason (required — no reason, no send), checkpoints the pass (from_session into progress), creates the session IN the worktree via claimant.py's transport, transfers the claim with the new verb, checkpoints launched, and sends launch_one's prompt + a SENDER NOTES section (notes verbatim) via claimant's verified _send_prompt. Any failure before the transfer lands deletes the created session and flips the assignment back to direct — the sender keeps the item. launch_one.build_prompt gains the optional sender_notes section; claimant prompt.md and all four lane runbooks (§1b) document the send + limitation.
Tests
- fleet-queue: 154 lib + 2 integration, 0 failed (new:
transfer_accepts_each_holder_session_mark_8210, transfer_refuses_poach_terminal_parked_expired_and_bound_8210, transfer_update_is_one_atomic_claimed_to_claimed_move_8210, lane_flip_to_opencode_only_unbound_direct_with_reason_8210, platform_limit_rules_8210).
- claimant suites: 117 tests OK (14 new send tests incl. happy path, rollback, prompt-failure-keeps-binding, muse-limitation refusal, reason-less limitation does not block).
Live acceptance (a real Muse-held task sent end-to-end, event history showing the direct transfer) runs against the deployed broker and is recorded on #8210.
![Autofix with [code]smith](/api/image?u=https%3A%2F%2Fcamo.githubusercontent.com%2F33b6f70f3541c4e93f4503d29cbfec051fa1b040d8e0ae9313a51c4ece44a627%2F68747470733a2f2f70722d636f6d6d656e74732d6173736574732e626c61636b736d6974682e73682f636f6465736d6974682f6175746f6669782d776974682d636f6465736d6974682d6461726b2d33782e706e67)
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
…session) + one-call send with notes and worktree (#8210)
…n the lane ledger, enforced by the transfer claim (#8210)
Codex Review Summary: ❌ Failed
This comment shows the latest Codex review activity on this pull request.
| Review |
Status |
Commit |
Review trigger |
| 📝 Code Review |
❌ Failed 2026-11-10T20:09:28.614776Z We couldn’t complete this review. Comment @codex review to try again. |
322c7cb |
PR opened |
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review" or "@codex security review".
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Warning
Review limit reached
You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.
Next included review available in 27 minutes.
Check out review usage here.
View limit details
-
Limit details: You’ve used the included review currently available.
Learn how review limits work.
Review configuration:
Run configuration
-
- Source mode: Auto
- Repository: Unavailable
- Branch: Unavailable
- File: No configuration file from this repository applied
- Commit: Unavailable
- Layers: defaults
- Review profile: CHILL
- Plan: Advanced
- Run ID:
728c59f8-5461-49ec-92ad-c85121e4f572
Commits
-
Reviewing files that changed from the base of the PR and between 19920ea and 322c7cb.
Files selected for processing: 6
-
pkgs/fleet/crates/fleet-queue/src/client.rs
pkgs/fleet/crates/fleet-queue/src/turso_queue.rs
pm-stack/opencode-claimant/launch_one.py
pm-stack/opencode-claimant/prompt.md
pm-stack/opencode-claimant/send_to_opencode.py
pm-stack/opencode-claimant/test_send_to_opencode.py
- Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Share
-
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, you can upgrade your account or add credits to your account and enable them for code reviews in your settings.
|
Sorry, something went wrong.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
This was referenced Nov 10, 2026
This was referenced Nov 21, 2026
Uh oh!
There was an error while loading. Please reload this page.
Assignees
No one assigned
Milestone
No milestone
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
|