Repository navigation
feat(android): connect live selected NSD candidates to one RVD1 session - #307
Open
turinglambdaai wants to merge 8 commits into
Open
turinglambdaai wants to merge 8 commits into
turinglambdaai wants to merge 8 commits into
Conversation
A resolved endpoint that DeviceCompanionEndpoint rejects threw from the queued worker task: the guard around worker.execute only covers task submission, so the shared worker thread died with the callback never invoked and a product UI waiting forever. Construction now fails through the same completion path as a failed dial. Staleness also compared the whole DeviceDiscovery, so a pairing-window flip between selection and worker start reported STALE_SELECTION for a device that is still present; presence now matches stable identity (service name plus listener ID) and the window is judged from the fresh advertisement, giving Pair intents the PAIRING_WINDOW_CLOSED code. JVM tests pin the rejected-endpoint callback, reconnect proceeding across a window flip, and pair failing closed with the right code.
turinglambdaai
marked this pull request as ready for review
October 22, 2026 15:48
The resolver's validate() rejects out-of-range ports before the coordinator's worker ever sees an endpoint, so the intended bad-endpoint scenario completes with STALE_SELECTION synchronously, not through the worker's construction guard; the guard stays as defense-in-depth but the test now pins the actual single-shot callback contract. Local gradle verification needs ANDROID_HOME now that the android-nsd module compiles in the same build.
This branch has not been deployed
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.
Scope
SelectedDeviceCompanionCoordinatorjoining explicit discovery/selected resolution to an authenticated, single-useDeviceCompanionSession.Validation
CI must pass prior to review/merge; no Android UI, secure-store integration, or real-device evidence claimed. Independent of PR #306. Base
1248a90cdf347edfb44731ff7c8f69c94df96d59.