From bc7bbbfc7bdee4afc76c636e98a8a02d686a133f Mon Sep 17 00:00:00 2001 From: Russell Ballestrini Date: Tue, 2 Jun 2026 12:46:41 -0400 Subject: [PATCH] =?UTF-8?q?zebra-spaces:=20log=20every=20screen/camera/gam?= =?UTF-8?q?e=20ontrack=20with=20state=20=E2=80=94=20diagnostic?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Listener reports seeing host's screen-share but NOT camera-share on rejoin. SFU log shows both pubs alive + addPubToSub fires for the new sub, but the listener-side visible result diverges between screen and camera. Add a log line that captures everything we know when each video-kind track lands: sfu ontrack: kind=camera pub=abc12345 track=video mute=true state=live Fields: - kind: which routing branch we took - pub: short pubHex prefix - track.kind: should be 'video' for screen/camera/game - track.muted: initial mute state (true is normal pre-RTP) - track.readyState: 'live' = good, anything else = bad Fox can paste the lines so we can see whether (a) the camera ontrack never fires (SFU subscribe SDP is dropping it), (b) it fires with track.muted=true and stays that way (no RTP arriving), or (c) it fires healthy and gets pruned by some downstream bug. --- web/zebra-spaces.html | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/web/zebra-spaces.html b/web/zebra-spaces.html index 25b065d..fdea041 100644 --- a/web/zebra-spaces.html +++ b/web/zebra-spaces.html @@ -2150,6 +2150,10 @@ async function sfuSubscribe(){ } } catch(_){} } + if (kind === 'screen' || kind === 'camera' || kind === 'game'){ + logLine('', 'sfu ontrack: kind=' + kind + ' pub=' + shortHex(pubHex) + + ' track=' + ev.track.kind + ' mute=' + ev.track.muted + ' state=' + ev.track.readyState); + } if (kind === 'screen'){ screenStreams.set(pubHex, ev.streams[0]); renderScreenTile(pubHex, ev.streams[0]); @@ -3505,8 +3509,8 @@ logLine('', 'ready โ€” pick a handle, type a rendezvous code, enter the space');