epifab / pypoker

Python poker game application (holdem, traditional 5 card draw)
https://pypoker.herokuapp.com
GNU General Public License v3.0
101 stars 50 forks source link

Cards not rendering and game not starting #10

Closed connorourke closed 3 years ago

connorourke commented 3 years ago

Hi,

I'm new to web-apps, and am trying to get a functioning one to tweak for a christmas lockdown poker game, so thanks for the nice example.

The demo deployed (https://pypoker.herokuapp.com/) seems to work fine, but when I clone and deploy it to heroku myself the table renders, but not the players or chips.

When I check the Heroku log files I see the following:

2020-12-12T14:25:22.502293+00:00 app[api]: Deploy 8a41d489 by user conn.orourke@gmail.com

2020-12-12T14:25:22.502293+00:00 app[api]: Release v9 created by user conn.orourke@gmail.com

2020-12-12T14:25:22.875487+00:00 heroku[web.1]: Restarting

2020-12-12T14:25:22.877759+00:00 heroku[web.1]: State changed from up to starting

2020-12-12T14:25:24.070090+00:00 heroku[web.1]: Stopping all processes with SIGTERM

2020-12-12T14:25:24.106975+00:00 app[web.1]: [2020-12-12 14:25:24 +0000] [4] [INFO] Handling signal: term

2020-12-12T14:25:24.872322+00:00 app[web.1]: [2020-12-12 14:25:24 +0000] [10] [INFO] Worker exiting (pid: 10)

2020-12-12T14:25:26.547287+00:00 heroku[web.1]: Starting process with command `gunicorn -k flask_sockets.worker client_web:app`

2020-12-12T14:25:29.905665+00:00 app[web.1]: [2020-12-12 14:25:29 +0000] [4] [INFO] Starting gunicorn 20.0.4

2020-12-12T14:25:29.905723+00:00 app[web.1]: [2020-12-12 14:25:29 +0000] [4] [INFO] Listening at: http://0.0.0.0:40769 (4)

2020-12-12T14:25:29.905723+00:00 app[web.1]: [2020-12-12 14:25:29 +0000] [4] [INFO] Using worker: flask_sockets.worker

2020-12-12T14:25:29.910536+00:00 app[web.1]: [2020-12-12 14:25:29 +0000] [9] [INFO] Booting worker with pid: 9

2020-12-12T14:25:29.991277+00:00 app[web.1]: [2020-12-12 14:25:29 +0000] [10] [INFO] Booting worker with pid: 10

2020-12-12T14:25:30.615301+00:00 heroku[web.1]: State changed from starting to up

2020-12-12T14:25:34.000000+00:00 app[api]: Build succeeded

2020-12-12T14:25:43.951326+00:00 app[web.1]: [2020-12-12 14:25:43,950] ERROR in client_web: Unable to connect player 5ca09e09-4717-4633-a838-8b9de59cf14f to a poker5 server: Timed out

2020-12-12T14:25:47.889391+00:00 heroku[router]: at=info method=GET path="/poker/texas-holdem" host=aqueous-hamlet-29943.herokuapp.com request_id=26028165-1786-4ba7-b56e-f3c15ae6a41e fwd="79.67.49.201" dyno=web.1 connect=1ms service=42232ms status=101 bytes=129 protocol=http

2020-12-12T14:25:48.752031+00:00 heroku[web.1]: Stopping all processes with SIGTERM

2020-12-12T14:25:54.149335+00:00 heroku[web.1]: Error R12 (Exit timeout) -> At least one process failed to exit within 30 seconds of SIGTERM

2020-12-12T14:25:54.151772+00:00 heroku[web.1]: Stopping remaining processes with SIGKILL

2020-12-12T14:25:54.165671+00:00 app[web.1]: [2020-12-12 14:25:54 +0000] [4] [INFO] Shutting down: Master

2020-12-12T14:25:54.249050+00:00 heroku[web.1]: Process exited with status 137

2020-12-12T14:25:55.308959+00:00 heroku[router]: at=info method=GET path="/" host=aqueous-hamlet-29943.herokuapp.com request_id=30a88add-116b-4a39-bc88-c420afd3c091 fwd="79.67.49.201" dyno=web.1 connect=0ms service=11ms status=200 bytes=2044 protocol=http

2020-12-12T14:25:55.563438+00:00 heroku[router]: at=info method=GET path="/static/css/bootstrap-slider.min.css" host=aqueous-hamlet-29943.herokuapp.com request_id=c7331882-8c69-4d83-8d1f-644019d52586 fwd="79.67.49.201" dyno=web.1 connect=1ms service=4ms status=200 bytes=7681 protocol=http

2020-12-12T14:25:55.469725+00:00 heroku[router]: at=info method=GET path="/static/css/bootstrap.min.css" host=aqueous-hamlet-29943.herokuapp.com request_id=da5d00a9-700d-4f7e-9689-f932b97ce8a2 fwd="79.67.49.201" dyno=web.1 connect=1ms service=8ms status=200 bytes=97620 protocol=http

2020-12-12T14:25:55.659099+00:00 heroku[router]: at=info method=GET path="/static/js/reconnecting-websocket.min.js" host=aqueous-hamlet-29943.herokuapp.com request_id=cc9cd3d5-4c8e-47b2-8e1d-a36c62c60c9a fwd="79.67.49.201" dyno=web.1 connect=1ms service=2ms status=200 bytes=2082 protocol=http

2020-12-12T14:25:55.561970+00:00 heroku[router]: at=info method=GET path="/static/css/TimeCircles.css" host=aqueous-hamlet-29943.herokuapp.com request_id=d974661e-ef3f-4a7d-8c0a-f3c291e12683 fwd="79.67.49.201" dyno=web.1 connect=0ms service=3ms status=200 bytes=1076 protocol=http

2020-12-12T14:25:55.572153+00:00 heroku[router]: at=info method=GET path="/static/js/jquery-2.0.3.min.js" host=aqueous-hamlet-29943.herokuapp.com request_id=fee333f3-06d7-4492-a954-8baa0ae56d1d fwd="79.67.49.201" dyno=web.1 connect=0ms service=5ms status=200 bytes=83907 protocol=http

2020-12-12T14:25:55.579040+00:00 heroku[router]: at=info method=GET path="/static/css/application.css" host=aqueous-hamlet-29943.herokuapp.com request_id=36645c0a-9968-4c3a-b76f-539a963276ed fwd="79.67.49.201" dyno=web.1 connect=4ms service=14ms status=200 bytes=7443 protocol=http

2020-12-12T14:25:55.578190+00:00 heroku[router]: at=info method=GET path="/static/js/bootstrap-slider.min.js" host=aqueous-hamlet-29943.herokuapp.com request_id=b535bb8c-2aee-4877-91e9-1ca449d3028e fwd="79.67.49.201" dyno=web.1 connect=1ms service=4ms status=200 bytes=30697 protocol=http

2020-12-12T14:25:55.663605+00:00 heroku[router]: at=info method=GET path="/static/js/TimeCircles.js" host=aqueous-hamlet-29943.herokuapp.com request_id=d749d29b-5949-40b1-ba8c-ad950a1d5d5a fwd="79.67.49.201" dyno=web.1 connect=1ms service=4ms status=200 bytes=34086 protocol=http

2020-12-12T14:25:55.675314+00:00 heroku[router]: at=info method=GET path="/static/js/application.js" host=aqueous-hamlet-29943.herokuapp.com request_id=8ae2f266-8ab0-4ed9-80a6-9de6d15b5e82 fwd="79.67.49.201" dyno=web.1 connect=0ms service=3ms status=200 bytes=22706 protocol=http

2020-12-12T14:25:56.230315+00:00 heroku[router]: at=info method=GET path="/poker/texas-holdem" host=aqueous-hamlet-29943.herokuapp.com request_id=d346d900-639a-41a8-96f8-c26a85eb8910 fwd="79.67.49.201" dyno=web.1 connect=1ms service=2ms status=101 bytes=129 protocol=http

2020-12-12T14:26:30.127231+00:00 heroku[router]: at=info method=POST path="/join" host=aqueous-hamlet-29943.herokuapp.com request_id=867fa8aa-9073-4813-886d-51fe84fcc661 fwd="79.67.49.201" dyno=web.1 connect=0ms service=9ms status=302 bytes=599 protocol=http

2020-12-12T14:26:30.230744+00:00 heroku[router]: at=info method=GET path="/" host=aqueous-hamlet-29943.herokuapp.com request_id=b934e242-9c76-4a9c-9234-ab3fde08800d fwd="79.67.49.201" dyno=web.1 connect=0ms service=10ms status=200 bytes=3125 protocol=http

2020-12-12T14:21:37.000000+00:00 app[heroku-redis]: source=REDIS addon=redis-encircled-80148 sample#active-connections=1 sample#load-avg-1m=0.21 sample#load-avg-5m=0.245 sample#load-avg-15m=0.265 sample#read-iops=0 sample#write-iops=0.058333 sample#memory-total=15664240kB sample#memory-free=11431788kB sample#memory-cached=1415360kB sample#memory-redis=330128bytes sample#hit-rate=1 sample#evicted-keys=0

Is the version on git the same as the one deployed in your working example?

Any ideas as to what the issue could be, and how to fix it?

Thanks

connorourke commented 3 years ago

Figured it out - needed to start the poker dyno.