CLIENT_LOG telemetry showed the phone re-promoted to speaker, published to SFU successfully, but neither the host nor the other speaker heard them. Cause: the page's ontrack handler skipped attaching SFU mic whenever peers.has(uuid) — even if that peer's mesh PC was in 'failed' or 'disconnected' state from an earlier role-change cycle. Fix two paths: 1. ontrack-side: only skip SFU mic when peers.get(uuid).connectionState is actually 'connected'. A stale entry or a failing PC no longer blocks the SFU fallback; receiver hears the publisher via SFU until mesh actually delivers. 2. mesh-fails-side: when an existing mesh PC transitions to 'failed', the audio element was bound to the dying mesh stream. Reach into sfuStreamsByPubHex and re-attach the cached SFU stream so the listener hears continuous audio while the mesh reconnect runs in the background, instead of a silent gap. Mesh stays the preferred path when it's actually working — only takes over the audio binding via its own ontrack when 'connected'. |
||
|---|---|---|
| .. | ||
| blog | ||
| fonts | ||
| chat.html | ||
| host-your-own.html | ||
| how-it-works.html | ||
| index.html | ||
| kernel.html | ||
| stamp.js | ||
| zebra-audio.html | ||
| zebra-spaces.html | ||