CharlieHess / slack-poker-bot

A bot that deals Texas Hold'em games in Slack
MIT License
1.66k stars 206 forks source link

Cards stopped dealing mid-game, returned empty set #25

Closed stephenyeargin closed 9 years ago

stephenyeargin commented 9 years ago

Odd behavior here. Halfway through a trial game, the card response began rendering as only , rather than as the text representation and images. Screenshots and log output from Heroku below.

screen shot 2015-09-02 at 10 13 26 am


2015-09-02T14:28:42.799364+00:00 app[web.1]: Welcome to Slack. You are pokerbot of Raven
2015-09-02T14:28:42.799654+00:00 app[web.1]: You are in: general, poker-room
2015-09-02T14:28:42.799819+00:00 app[web.1]: Your open DM's: slackbot, henshaw, irene, nate, megan, lizzie, leah, i, kevin, steve, tamara
2015-09-02T14:28:44.582408+00:00 heroku[router]: at=info method=GET path="/" host=raven-poker-bot.herokuapp.com request_id=da87b9f6-b621-475a-a34b-6565aed5e5a6 fwd="50.232.2.81" dyno=web.1 connect=3ms service=7ms status=200 bytes=128
2015-09-02T14:28:44.926244+00:00 heroku[router]: at=info method=GET path="/favicon.ico" host=raven-poker-bot.herokuapp.com request_id=b55ebe81-205b-4ff2-bd68-f571d3fb37af fwd="50.232.2.81" dyno=web.1 connect=2ms service=4ms status=200 bytes=128
2015-09-02T14:35:43.664697+00:00 app[web.1]: Creating board image timed out
2015-09-02T14:36:15.581307+00:00 app[web.1]: Creating board image timed out
2015-09-02T14:36:16.620460+00:00 app[web.1]: Creating board image timed out
2015-09-02T14:36:17.754729+00:00 app[web.1]: npm ERR! Linux 3.13.0-61-generic
2015-09-02T14:36:17.688518+00:00 app[web.1]: /app/node_modules/rx/dist/rx.js:579
2015-09-02T14:36:17.688525+00:00 app[web.1]:     throw e;
2015-09-02T14:36:17.688527+00:00 app[web.1]:           ^
2015-09-02T14:36:17.688529+00:00 app[web.1]: TypeError: Cannot read property 'toString' of undefined
2015-09-02T14:36:17.688530+00:00 app[web.1]:     at /app/src/hand-evaluator.js:24:53
2015-09-02T14:36:17.688531+00:00 app[web.1]:     at Array.map (native)
2015-09-02T14:36:17.688533+00:00 app[web.1]:     at Function.evaluateHands (/app/src/hand-evaluator.js:24:37)
2015-09-02T14:36:17.688535+00:00 app[web.1]:     at PotManager.endHandWithShowdown (/app/src/pot-manager.js:184:34)
2015-09-02T14:36:17.688536+00:00 app[web.1]:     at AnonymousObserver._onNext (/app/src/texas-holdem.js:450:27)
2015-09-02T14:36:17.688538+00:00 app[web.1]:     at AnonymousObserver.Rx.AnonymousObserver.AnonymousObserver.next (/app/node_modules/rx/dist/rx.js:1778:12)
2015-09-02T14:36:17.688540+00:00 app[web.1]:     at AnonymousObserver.Rx.internals.AbstractObserver.AbstractObserver.onNext (/app/node_modules/rx/dist/rx.js:1710:35)
2015-09-02T14:36:17.688541+00:00 app[web.1]:     at AnonymousObserver.tryCatcher (/app/node_modules/rx/dist/rx.js:567:29)
2015-09-02T14:36:17.688543+00:00 app[web.1]:     at AutoDetachObserverPrototype.next (/app/node_modules/rx/dist/rx.js:5274:51)
2015-09-02T14:36:17.688544+00:00 app[web.1]:     at AutoDetachObserver.Rx.internals.AbstractObserver.AbstractObserver.onNext (/app/node_modules/rx/dist/rx.js:1710:35)
2015-09-02T14:36:17.748737+00:00 app[web.1]: 
2015-09-02T14:36:17.755397+00:00 app[web.1]: npm ERR! argv "/app/.heroku/node/bin/node" "/app/.heroku/node/bin/npm" "start"
2015-09-02T14:36:17.755714+00:00 app[web.1]: npm ERR! node v0.12.7
2015-09-02T14:36:17.756687+00:00 app[web.1]: npm ERR! npm  v2.11.3
2015-09-02T14:36:17.757045+00:00 app[web.1]: npm ERR! code ELIFECYCLE
2015-09-02T14:36:17.757295+00:00 app[web.1]: npm ERR! slack-poker-bot@0.0.9 start: `node src/main.js`
2015-09-02T14:36:17.757431+00:00 app[web.1]: npm ERR! Exit status 1
2015-09-02T14:36:17.757670+00:00 app[web.1]: npm ERR! 
2015-09-02T14:36:17.757916+00:00 app[web.1]: npm ERR! Failed at the slack-poker-bot@0.0.9 start script 'node src/main.js'.
2015-09-02T14:36:17.758307+00:00 app[web.1]: npm ERR! This is most likely a problem with the slack-poker-bot package,
2015-09-02T14:36:17.758515+00:00 app[web.1]: npm ERR! not with npm itself.
2015-09-02T14:36:17.758728+00:00 app[web.1]: npm ERR! Tell the author that this fails on your system:
2015-09-02T14:36:17.758930+00:00 app[web.1]: npm ERR!     node src/main.js
2015-09-02T14:36:17.759335+00:00 app[web.1]: npm ERR!     npm owner ls slack-poker-bot
2015-09-02T14:36:17.759130+00:00 app[web.1]: npm ERR! You can get their info via:
2015-09-02T14:36:17.759548+00:00 app[web.1]: npm ERR! There is likely additional logging output above.
2015-09-02T14:36:17.762431+00:00 app[web.1]: 
2015-09-02T14:36:17.762992+00:00 app[web.1]: npm ERR! Please include the following file with any support request:
2015-09-02T14:36:17.763193+00:00 app[web.1]: npm ERR!     /app/npm-debug.log
2015-09-02T14:36:18.633695+00:00 heroku[web.1]: State changed from crashed to starting
2015-09-02T14:36:18.633695+00:00 heroku[web.1]: State changed from up to crashed
2015-09-02T14:36:18.618224+00:00 heroku[web.1]: Process exited with status 1
2015-09-02T14:36:24.782187+00:00 heroku[web.1]: Starting process with command `npm start`
2015-09-02T14:36:33.369007+00:00 app[web.1]: 
2015-09-02T14:36:33.369027+00:00 app[web.1]: > slack-poker-bot@0.0.9 start /app
2015-09-02T14:36:33.369029+00:00 app[web.1]: > node src/main.js
2015-09-02T14:36:33.369030+00:00 app[web.1]: 
stephenyeargin commented 9 years ago

Looks very similar to #14 (see three debug points before error). I think the desired behavior would be to return the text representation even if the images fail to generate.

CharlieHess commented 9 years ago

Yep, looks like a dupe of #14. I'll try to knock this out over the weekend.