Repository navigation
feat(automations): label workspaces a host creates with the desktop's own automation run - #35986
Merged
nwparker merged 2 commits intoOct 29, 2026
Merged
Conversation
… own automation run A desktop's own automation could create its workspace on a managed or paired host, but the workspace lost its automation identity: no badge, and its run pane closed instead of sleeping. The desktop now sends a capable host its run as a label, naming itself (`local`) as the automation's owner. The host records it with origin 'client', only for automations it does not hold, caps its fields, and never lets a client-origin label grant run ownership, sleep authority or automation create policy. Older hosts get nothing new; older desktops still create plain workspaces. A client-origin label whose automation can't be found reads as unavailable, not removed. Refs #34433
Contributor
Finishing Touches
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. Comment |
[Medium impact] The PR appears safe to merge; no actionable issues were found. SummaryAdds automation labels to workspaces that a desktop creates on capable runtime hosts.
nwparker explicitly describes other desktops showing “unavailable” as intentional.
|
nwparker
deleted the
feat/34433-host-records-client-automation-provenance
branch
October 29, 2026 16:10
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
ELI5
When a desktop's own automation creates its workspace on a managed or paired Orca host, that workspace used to lose its automation identity: no automation badge, and the run's pane closed instead of sleeping when the run finished. Now the desktop tells a capable host "this workspace belongs to my automation run". The host stores that as a label, so the badge and sleep-on-finish work again.
What Changed
worktree.create.client-automation-provenance.v1, the desktop sends the run asclientAutomationProvenance.local) as the automation's owner, so the badge looks the automation up on this desktop.automationProvenancewithorigin: 'client'and a host-stampedcreatedAt, but only for automations it doesn't hold itself.runOwnsWorkspace);allowLocalBaseFallbackandwslUserActstay as for a plain create).Why
Only the desktop's own process can check its dispatch token. #34525 stopped sending the token to hosts, and #35978 made hosts accept older desktops that still send it. Both left these workspaces unlabelled. A host can't verify a client's claim either way, so the record is treated as what it is: a cosmetic label. The host stores it but never acts on it.
Earlier I had the desktop check its token before sending. I dropped that: it added IPC and new ways for a run to fail, and gave the host no extra trust. Any paired client could already label its own new workspaces, so trust is unchanged.
Mixed versions:
The field is optional, and the host accepts any value and validates it itself, so a bad label can't fail a create.
Linked Issue
Refs #34433
Thanks @nm7-jp for the report.
Visual Proof
N/A. The badge rendering is unchanged; it now appears on these workspaces again. The new "unavailable" state reuses the existing copy ("Automation availability could not be checked.").
Testing
localas the owner;