ctm / mb2-doc

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

Logged out after redeploy #1379

Closed ctm closed 2 months ago

ctm commented 2 months ago

Fix the problem that prevents a logged in player from being logged in after a deploy.

This happened after yesterday's pre-game deploy that had the major Nick work and I ascribed it to the change I made to session storage. However, I just did a morning deploy and it happened to me. D'oh!

To some extent this validates my belief that I should get all this Nick foofaraw out of the way before mentioning craftpoker.com to a wider audience, but it also points out that I could have done a little more testing before deploying.

ctm commented 2 months ago

Trivially reproducible locally. It looks like mb2 may accidentally not be respecting the Credentials stored in a PendingReconnect. Either that or we're accidentally switching to LoggedOut instead of PendingReconnect.

ctm commented 2 months ago

Both of the above problems were present, but in addition to that, I believe that PendingReconnect needs to preserve the unload handler, and it also looks like mb2 may be thinking that the client has changed when it hasn't. The latter may be a regression that I introduced previously and never noticed since the vast majority of my deploys to craftpoker.com do involve client changes.

ctm commented 2 months ago

Fixed in master. I'm trying to deploy now, but I have to do it through my phone.