approver: silence ⚠️ timeout for lobby rooms nobody joined#41
Merged
Conversation
Every POST /join/api mints a fresh lobby room. In prod the same shared signup code (`XsqpEfyP`, 20 uses) gets opened by link-preview bots in Slack/Element/iMessage, accidental reloads, and aborted clicks — each creates a room with `challenged=[]` that then expires 2h later. That fires `⚠️ lobby failed for (no users joined)` once per ghost room, and the operator notify room sees clusters of 3+ such messages around each actual signup. Suppress the announcement when `closed_reason == "timeout"` and `challenged` is empty. Still mark the room as seen so the announce loop doesn't re-evaluate it forever. Timeouts where a user actually joined but didn't finish the haiku (the actionable bucket) still fire. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
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.
Summary
/join/api, which mints a fresh public room withchallenged=[]. 2h later the cleanup sweeper closes those rooms withclosed_reason="timeout"and the operator notify room sees a⚠️ lobby failed for (no users joined)for every one of them — clusters of 3+ around each actual signup.challenged, marks the room as seen so the announce loop doesn't re-evaluate it forever, and keeps firing for the actionable bucket (user joined, never completed the haiku).Test plan
python3 tests/announce_unit.py— all four tests pass, including the newtest_ghost_timeout_suppressed_but_real_timeout_announcedwhich models open→timeout transition with one ghost room and one room where a user actually joined.test_no_flood_on_historical_closed_rooms,test_open_room_still_announced,test_seen_persists_across_cycles_for_open_then_closed) still pass.⚠️ lobby failed for (no users joined)messages appear in the operator notify room over a 24h window.⚠️ lobby failed for @user:server (reason=timeout, code=…).🤖 Generated with Claude Code