Repository navigation
fix(game): make the start button work when the lobby is full - #116
Merged
Merged
Conversation
When the fifth player joined, the join keyboard was replaced by a start button with callback data "start". The start callback handler only matches "start_<game_id>", so pressing it did nothing and a full lobby could never be started. get_start_keyboard now takes the game id and uses "start_<game_id>", like the start button of the join keyboard. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KouGQtM6VBedfBdNr8WFX5
1 similar comment
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.
Requested by Rico · project thread
Before: when the fifth player joined a group game, the Join/Start keyboard was replaced with a single Start button that did nothing when pressed. A full lobby could never start.
After: the Start button on a full lobby starts the game, the same way the Start button on the join keyboard does.
How:
get_start_keyboardusedcallback_data="start", butstart_callback_handleronly matches^start_[0-9]{7}$. Even if it had matched,is_button_affiliatedneeds the game id in the data.get_start_keyboardnow takes the game id and emitsstart_<game_id>, and both call sites injoin_callbackpassgame.id. New tests check that the start buttons on both keyboards match the start handler's pattern.🤖 Generated with Claude Code
https://claude.ai/code/session_01KouGQtM6VBedfBdNr8WFX5
Generated by Claude Code