Repository navigation
Conversation
Expose mobile pairing offer minting and network interface enumeration over the JSON-RPC WebSocket channel so authenticated web clients can do what the Electron IPC handlers (mobile:getPairingQR etc.) already do. The new delegates reuse the server-side createMobilePairingOffer / createPairingOffer logic, so a web-minted QR is byte-compatible with the existing phone pairing flow (LAN/Tailscale direct endpoints included).
Replace the listNetworkInterfaces / getPairingQR / getRuntimePairingUrl stubs with routing over the pairing.* RPC methods so the web UI can list LAN/Tailscale addresses and mint scannable QRs. Device management and Windows-only stubs stay in place: registry RPC is out of scope.
espetro
pushed a commit
that referenced
this pull request
Nov 30, 2026
…e share a name (stablyai#52701) Check runs were keyed by suite and name, so two same-named runs in one suite shared one saved row. Every poll one of them carried a different run id than the saved row and read as a rerun, posting a new "CI green" line for the same head. Sort observed runs by run id and suffix repeated names (#2, #3) so each run keeps its own row and an unchanged read compares equal. Fixes stablyai#52700 Co-authored-by: Neil <[email protected]>
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.
Problem
In the orca-serve web UI, the "orca mobile" connect step could not list network interfaces (no Tailscale option) and QR minting failed with "WebSocket transport is not running".
Root cause:
web-mobile-api.tshard-stubbedlistNetworkInterfaces -> []andgetPairingQR -> { available: false }after the upstream preload refactor (stablyai#16181). The pairing machinery itself is pure Node and already runs in the headless orcad process; it was unwired for web, not blocked.Changes
Server (feat(rpc))
PAIRING_METHODS:pairing.mintOffer— wrapscreateMobilePairingOffer(same logic as desktopmobile:getPairingQR), encodes the QR server-side, fails closed with guidance whenlocal-onlyreach has no advertisable addresspairing.listNetworkInterfaces— purenode:osenumeration, Tailscale (100.x) addresses ranked firstpairing.getRuntimePairingUrl— mirrors desktopmobile:getRuntimePairingUrl, including the network-exposure widen and its failure guidancePairingRpcContextgained optional minting delegates; the WebSocket dispatch wires them off the authenticated runtime server. Phones cannot call the new methods: they are not inMOBILE_RPC_METHOD_ALLOWLIST, so only authenticated runtime-scope (web/desktop) clients can.Web client (feat(web))
web-mobile-api.tsun-stubslistNetworkInterfaces/getPairingQR/getRuntimePairingUrlby routing overcallRuntimeResult(pattern fromweb-runtime-calls.ts). Interface listing soft-fails to an empty list.listDevices/revokeDevice/ runtime access grants) and Windows-only firewall APIs remain stubbed — they need a registry-backed RPC namespace and are out of scope here.Byte-compatible QR
The minted QR carries the same
endpoint + device token + host pubkeypayload as the desktop flow (LAN/tailnet direct endpoints included), so the existing phone app pairs with no changes. No new transport, no REST, no WebRTC.Testing
pairing.test.ts: 6 cases (direct-only QR with advertised tailnet address, unavailable pass-through with reason/guidance, invalid-argument rejection, interface listing)web-mobile-api.test.ts: routing assertions against mockedcallRuntimeResultincl. soft-fail behaviorpnpm tc:node,pnpm tc:web, changed-code quality gate all cleanFollow-ups (not in this PR)
orca-serve