Replace HeadsetHold inference with route-heard ownership #59
Loading…
Reference in a new issue
No description provided.
Delete branch "mcp/issue-11-route-heard-ownership"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #11.
Old ownership model
Routing continuity was inferred across several pieces of state:
heardAudio,HeadsetHold.remembered,releasedToCar, frameworkisActiveobservations, andAudioOutputRoles.startTarget(). Different output-selection callers could therefore retire or resurrect that state differently, and system-policy route enumeration could compete with explicit listener intent.New ownership model
RouteHeardOwnershipholds the strongest trustworthy route evidence for the currently loaded book/session generation.getAudioDevicesForAttributesremains described as attributes/system-policy evidence, not proof of BookWave's exact AudioTrack sink.Deleted inference state
The old
HeadsetHoldstate machine,heardAudio,releasedToCar, andstartTarget()inference path are removed rather than layered beside the new owner.Regression coverage
Focused ownership tests cover:
Ambiguous;Existing output-role tests retain the settled ADR-0029 contract: Car means Automatic/platform routing and Headset targets only legitimate headset candidates.
Verification
pull-request.ymlrun 112 (Actions run id 114) passed on exact head5f0e9184fd96df0b9500ac74ceb4885a8cb7d187.11d3472e9f1ebf2e7e18548974b9c6e7570e1b76,headsetForCarwas deliberately changed to treat any connected headset as heard. The ownership suite failed as required, including:The mutation run was cancelled after the proof and the branch was deleted.
Device evidence still required
JVM/CI coverage proves BookWave's ownership, generation and precedence rules. It does not prove Android's route-policy observation is the exact sink carrying BookWave's track. Physical headset + phone-speaker + Android Auto/head-unit acceptance remains required before that platform boundary is called fully accepted.
Explicit non-goal
This PR does not implement #36 automatic resume behavior. A car arriving may still leave playback paused; no new play/resume-on-car-connection path is introduced.