ctm / mb2-doc

Mb2, poker software
https://devctm.com
7 stars 2 forks source link

fold to any bet bug #1102

Closed ctm closed 1 year ago

ctm commented 1 year ago

Fix the bug described below

I have experienced this bug several times, including just a few hands ago (you may have seen my comment in chat). When I select Fold to any bet, when the action reaches me, my hand isn’t folded, but all of my action options are gone. I get a timeout alarm and then actually time out (go on vacation).

I haven’t experimented with this bug much, and I’m not sure how reproduceable it is, but it has happened to me at least 3 times. I will give you more detail when I have it.

I'm labeling this easy, because I'm hoping it's reproducible. I also figure I can find the hand where it happened (in this evening's game).

ctm commented 1 year ago

Here's the chat:

mb2=> select id, table_id, hand_id, message from public_table_messages where id = 8176817;
   id    | table_id | hand_id |       message        
---------+----------+---------+----------------------
 8176817 |     4834 |  320258 | {"Chat": [redacted, "wtf"]}
(1 row)

That is indeed the hand where it happened:

 8176809 | 2023-01-26 01:05:52.569638+00 |      66 | {"Remind": [20000, 0, "2023-01-26T01:06:12.554010730Z", redacted, 20]}
 8176817 | 2023-01-26 01:06:09.765336+00 |      44 | {"Chat": [redacted, "wtf"]}
 8176818 | 2023-01-26 01:06:12.557081+00 |      31 | {"Vacationed": redacted}

Since I have the hand number, I can examine all the interactions between that player and the server and try to figure out what happened. I don't think a force-status build will help,, so if it's not obvious via code inspection I may have to add functionality to force-status.

I'm not sure when I'll make time to work on this. I absolutely hate that this bug exists, but I'm crazy behind on important non-programming stuff.

ctm commented 1 year ago

I can reproduce this with force-status, but only if I pay attention to what I'm doing. Initially I thought the protaganist chose Fold To Any Bet pre-flop and that worked fine. It turns out, the protaganist called pre-flop and then chose Fold To Any Bet when it was his turn to act, but there was no action to him and that doesn't work. D'oh!

ctm commented 1 year ago

Fixed (and tested!). Deploying now.