joule-moq-room: the clock's events track is published with each grant, so a viewer can enter an empty room #529
Loading…
Reference in a new issue
No description provided.
Delete branch "room/viewer-of-an-empty-room"
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?
On wai.transaction.science a viewer cannot enter the live room while nobody is in it.
/room/'s Watch, and WAI Studio's Rooms panel, both stop at "entering" withSUBSCRIBE <room>/<clock>/events--0: REQUEST_ERROR 2 no publisher within RENDEZVOUS_TIMEOUT. Found by the Studio's production e2e on 2026-10-29. Restarting the room service doesn't help: a fresh room refuses its viewer the same way.Cause. The clock published its events track at the room's first event, which is a publisher's
join. A viewer's first step is to subscribe to that track. In an empty room it has no publisher, so the relay refuses the subscription at its rendezvous wait. Every test let a publisher enter first, so none of them saw this.Change.
Service::open_events(generation)publishes the clock's events track if it isn't published yet. Each grant spawns it, so the track is there by the time the grantee subscribes. The first event takes the same path (events_track), so the track is still published once per room.Test.
room_service::a_viewer_enters_a_room_nobody_has_joined: a viewer is granted in an empty room and its subscription to the clock's events track is answered. Then a publisher enters, and the clock'sjoinreaches the viewer on that subscription.cargo test --locked --all-targetsinjoule-moq-room(whatjoule-moq-room.ymlruns) passes there: every test, 0 failed.The README's "authors the lifecycle" says when the track is published.
After merge, the room service on prod (
~/sites/wai-room/joule-moq-room, launchdscience.transaction.wai-room) is rebuilt from main and restarted.🤖 Generated with Claude Code
The clock published its events track at the room's first event, a publisher's join. A viewer who entered a room nobody had joined subscribed to a track with no publisher, and the relay refused it at its rendezvous wait ("no publisher within RENDEZVOUS_TIMEOUT"): on wai.transaction.science, /room/'s Watch and WAI Studio's Rooms panel never entered while the room was empty. The track is now published by Service::open_events, which each grant spawns; the first event uses the same path (events_track), so the track is published once per room. room_service: a_viewer_enters_a_room_nobody_has_joined, a viewer's subscription answered in an empty room and the first publisher's join reaching it. Co-Authored-By: Claude Opus 5.5 <[email protected]>