agent-device: which cross-worktree device ownership and release commands have shipped?
In agent-device (callstack/agent-device), how is device ownership handled across multiple worktree daemons? The original plan mentioned
device status,device release --stale, anddevice release --force, along withDEVICE_IN_USEandCOMMAND_FAILEDerrors. Which of these shipped, and what recovery behavior is available now?Originally asked on GitHub: https://github.com/callstack/agent-device/issues/1320
2 answers
Status: fixed in the issue's closing comment, but with unverified merges. The issue is closed as COMPLETED. The last comment lists three PRs (#2160, #2162, #2165) as the finishing stack and says #2165 closes the issue on merge. The thread does not confirm that those PRs merged.
What the thread states as shipped:
- Stage 0 (#1323, commit
630e0bb65):agent-device daemon stop --state-dir <path>with verified graceful shutdown, bounded forced escalation, and--cleanfor retained daemon-owned resources. - Stage 1 (#1328): advisory host-global device claims and daemonless
device status, which reports host-local claims only. - Hardening and later stages (#1735, #1809, #1647, #1818, #2057, #2105): listed as shipped and hardened, without per-PR detail in the thread.
The finishing stack, as proposed:
- #2160: a daemon holding the device claim stops and replaces a warm Apple runner whose owner no longer holds the claim. Before this, a loser could wait up to about 5 minutes of unstructured
COMMAND_FAILEDrunner-prep rejection. - #2162:
device release --staleclears provably dead owners daemonlessly. Dead-ownerDEVICE_IN_USEconflicts show the exact release command, anddaemon stopreports orphaned claims. - #2165:
devicesrows show the blocking claim owner, andhelp debuggingdocuments the twoDEVICE_IN_USEflavors.
Out of scope per the 2026-07-24 correction:
device release --force, remote lease projection in status and release, and claim-aware auto-selection for selector-lessopen. Live-owner conflicts are a non-retriable block, and agents should use existing owner or session workflows.Did this work for you?- Stage 0 (#1323, commit
What @thymikee tried on GitHub (Worked)
Maintainers live-validated the finishing stack against real two-daemon setups sharing one claim store, covering protection, about 8s takeover with the losing daemon still alive, the loser-shutdown guard, daemonless release of a planted dead owner, and ownership projection.
Source: https://github.com/callstack/agent-device/issues/1320#issuecomment-5477244321 (opens external site)
Did this work for you?
Related questions
- agent-device open <package> fails on Android apps with multiple launcher activities
- agent-device web screenshot: how to capture the full page instead of the viewport?
- Why does agent-device take ~6.7s to resolve an Apple device, and can usbmuxd replace devicectl/xctrace?
- Why does agent-device iOS text-entry fail with TEXT_INPUT_COMMIT_NOT_OBSERVED intermittently on the simulator?
- agent-device daemon: client tenant trusted when auth hook doesn't attest tenantId?