showdownbot icon indicating copy to clipboard operation
showdownbot copied to clipboard

Can't start a battle...

Open PartyOfBardsS17 opened this issue 6 years ago • 1 comments

This project looks great! I am building a similar project for a year long AI course. I tried running the bot and got a few problems. This issue appears to be that I can't start a battle because it can't find a room/doesn't know how to pick a format. I understand that you may not want to rework the code. But I would be super grateful if you would point me in the right direction. Below the error I got and the settings I used in the command line:

node bot.js --ranked --net create --algorithm minimax -- nosave --nolog --startchallenging
[2017-11-28 23:59:25.839] [INFO] learning - Creating neural network... [2017-11-28 23:59:25.847] [INFO] learning - Created neural network... [2017-11-28 23:59:25.848] [TRACE] learning - Created SGD Trainer [2017-11-28 23:59:25.904] [INFO] webconsole - Started web console on port 3000... [2017-11-28 23:59:26.024] [INFO] bot - Connected to server. [2017-11-28 23:59:26.025] [TRACE] bot - << |updateuser|Guest 324953|0|101 |formats|,1|US/UM Singles|[Gen 7] Random Battle,f|[Gen 7] Unrated Random Battle,b|[Gen 7] OU,e|[Gen 7] Ubers,e|[Gen 7] UU,e|[Gen 7] RU,e|[Gen 7] NU,e|[Gen 7] PU,e|[Gen 7] LC,e|[Gen 7] Monotype,e|[Gen 7] Anything Goes,e|[Gen 7] CAP,e|[Gen 7] CAP LC,c|[Gen 7] Battle Spot Singles,1e|[Gen 7] Battle Spot Special 7,1e|[Gen 7] Dragon Cup,1e|[Gen 7] Custom Game,c|,1|US/UM Doubles|[Gen 7] Random Doubles Battle,f|[Gen 7] Doubles OU,e|[Gen 7] Doubles Ubers,e|[Gen 7] Doubles UU,e|[Gen 7] VGC 2018,1e|[Gen 7] VGC 2017,1e|[Gen 7] Battle Spot Doubles,1e|[Gen 7] Doubles Custom Game,c|,2|OM of the Month|[Gen 7] Full Potential,e|[Gen 7] Dual Wielding,e|,2|Other Metagames|[Gen 7] Balanced Hackmons,e|[Gen 7] 1v1,e|[Gen 7] Mix and Mega,e|[Gen 7] Almost Any Ability,e|[Gen 7] Camomons,e|[Gen 7] STABmons,c|[Gen 7] 2v2 Doubles,c|[Gen 6] Gen-NEXT OU,c|,2|Randomized Metas|[Gen 6] Battle Factory,f|[Gen 7] BSS Factory,f|[Gen 7] Monotype Random Battle,d|[Gen 7] Challenge Cup 1v1,f|[Gen 7] Challenge Cup 2v2,d|[Gen 7] Hackmons Cup,f|[Gen 7] Doubles Hackmons Cup,d|[Gen 6] Random Battle,f|[Gen 5] Random Battle,f|[Gen 4] Random Battle,f|[Gen 3] Random Battle,f|[Gen 2] Random Battle,f|[Gen 1] Random Battle,f|[Gen 1] Challenge Cup,9|,3|RoA Spotlight|[Gen 5] PU,e|,3|OR/AS Singles|[Gen 6] OU,e|[Gen 6] Ubers,e|[Gen 6] UU,e|[Gen 6] RU,e|[Gen 6] NU,e|[Gen 6] PU,e|[Gen 6] LC,e|[Gen 6] Anything Goes,e|[Gen 6] Monotype,c|[Gen 6] CAP,c|[Gen 6] Battle Spot Singles,1e|[Gen 6] Inverse Battle,c|[Gen 6] Custom Game,c|,3|OR/AS Doubles/Triples|[Gen 6] Doubles OU,e|[Gen 6] Doubles Ubers,c|[Gen 6] Doubles UU,c|[Gen 6] VGC 2016,1e|[Gen 6] Battle Spot Doubles,1e|[Gen 6] Doubles Custom Game,c|[Gen 6] Battle Spot Triples,1e|[Gen 6] Triples Custom Game,c|,4|B2/W2 Singles|[Gen 5] OU,e|[Gen 5] Ubers,e|[Gen 5] UU,e|[Gen 5] RU,e|[Gen 5] NU,e|[Gen 5] LC,e|[Gen 5] GBU Singles,1c|[Gen 5] Custom Game,c|,4|B2/W2 Doubles|[Gen 5] Doubles OU,e|[Gen 5] GBU Doubles,1c|[Gen 5] Doubles Custom Game,c|,4|Past Generations|[Gen 4] OU,e|[Gen 4] Ubers,e|[Gen 4] UU,e|[Gen 4] NU,c|[Gen 4] LC,e|[Gen 4] Custom Game,c|[Gen 4] Doubles Custom Game,c|[Gen 3] OU,e|[Gen 3] Ubers,e|[Gen 3] Custom Game,c|[Gen 3] Doubles Custom Game,c|[Gen 2] OU,e|[Gen 2] Ubers,c|[Gen 2] Custom Game,c|[Gen 1] OU,e|[Gen 1] Ubers,c|[Gen 1] OU (tradeback),c|[Gen 1] Stadium,c|[Gen 1] Custom Game,c [2017-11-28 23:59:26.026] [TRACE] bot - << |formats|,1|US/UM Singles|[Gen 7] Random Battle,f|[Gen 7] Unrated Random Battle,b|[Gen 7] OU,e|[Gen 7] Ubers,e|[Gen 7] UU,e|[Gen 7] RU,e|[Gen 7] NU,e|[Gen 7] PU,e|[Gen 7] LC,e|[Gen 7] Monotype,e|[Gen 7] Anything Goes,e|[Gen 7] CAP,e|[Gen 7] CAP LC,c|[Gen 7] Battle Spot Singles,1e|[Gen 7] Battle Spot Special 7,1e|[Gen 7] Dragon Cup,1e|[Gen 7] Custom Game,c|,1|US/UM Doubles|[Gen 7] Random Doubles Battle,f|[Gen 7] Doubles OU,e|[Gen 7] Doubles Ubers,e|[Gen 7] Doubles UU,e|[Gen 7] VGC 2018,1e|[Gen 7] VGC 2017,1e|[Gen 7] Battle Spot Doubles,1e|[Gen 7] Doubles Custom Game,c|,2|OM of the Month|[Gen 7] Full Potential,e|[Gen 7] Dual Wielding,e|,2|Other Metagames|[Gen 7] Balanced Hackmons,e|[Gen 7] 1v1,e|[Gen 7] Mix and Mega,e|[Gen 7] Almost Any Ability,e|[Gen 7] Camomons,e|[Gen 7] STABmons,c|[Gen 7] 2v2 Doubles,c|[Gen 6] Gen-NEXT OU,c|,2|Randomized Metas|[Gen 6] Battle Factory,f|[Gen 7] BSS Factory,f|[Gen 7] Monotype Random Battle,d|[Gen 7] Challenge Cup 1v1,f|[Gen 7] Challenge Cup 2v2,d|[Gen 7] Hackmons Cup,f|[Gen 7] Doubles Hackmons Cup,d|[Gen 6] Random Battle,f|[Gen 5] Random Battle,f|[Gen 4] Random Battle,f|[Gen 3] Random Battle,f|[Gen 2] Random Battle,f|[Gen 1] Random Battle,f|[Gen 1] Challenge Cup,9|,3|RoA Spotlight|[Gen 5] PU,e|,3|OR/AS Singles|[Gen 6] OU,e|[Gen 6] Ubers,e|[Gen 6] UU,e|[Gen 6] RU,e|[Gen 6] NU,e|[Gen 6] PU,e|[Gen 6] LC,e|[Gen 6] Anything Goes,e|[Gen 6] Monotype,c|[Gen 6] CAP,c|[Gen 6] Battle Spot Singles,1e|[Gen 6] Inverse Battle,c|[Gen 6] Custom Game,c|,3|OR/AS Doubles/Triples|[Gen 6] Doubles OU,e|[Gen 6] Doubles Ubers,c|[Gen 6] Doubles UU,c|[Gen 6] VGC 2016,1e|[Gen 6] Battle Spot Doubles,1e|[Gen 6] Doubles Custom Game,c|[Gen 6] Battle Spot Triples,1e|[Gen 6] Triples Custom Game,c|,4|B2/W2 Singles|[Gen 5] OU,e|[Gen 5] Ubers,e|[Gen 5] UU,e|[Gen 5] RU,e|[Gen 5] NU,e|[Gen 5] LC,e|[Gen 5] GBU Singles,1c|[Gen 5] Custom Game,c|,4|B2/W2 Doubles|[Gen 5] Doubles OU,e|[Gen 5] GBU Doubles,1c|[Gen 5] Doubles Custom Game,c|,4|Past Generations|[Gen 4] OU,e|[Gen 4] Ubers,e|[Gen 4] UU,e|[Gen 4] NU,c|[Gen 4] LC,e|[Gen 4] Custom Game,c|[Gen 4] Doubles Custom Game,c|[Gen 3] OU,e|[Gen 3] Ubers,e|[Gen 3] Custom Game,c|[Gen 3] Doubles Custom Game,c|[Gen 2] OU,e|[Gen 2] Ubers,c|[Gen 2] Custom Game,c|[Gen 1] OU,e|[Gen 1] Ubers,c|[Gen 1] OU (tradeback),c|[Gen 1] Stadium,c|[Gen 1] Custom Game,c [2017-11-28 23:59:26.027] [WARN] bot - Did not recognize command of type: formats [2017-11-28 23:59:26.027] [TRACE] bot - << |queryresponse|rooms|null [2017-11-28 23:59:26.028] [WARN] bot - Did not recognize command of type: queryresponse [2017-11-28 23:59:26.028] [TRACE] bot - << |challstr|4|6882b223468a13b122770037ded1f97f2a0f09be32b1d7c2a151a8c7ea7471b6cb3b66e70f05128f4f00b94b904908c0362f24a04bb99ec8ca37dd8503103dea69e2de1adf0810414735efa1acdb7062a894e4425f350d27b59b4cc676a585fec601889d962fdde3eb2179f6e156da2993a9c366f9d1d1e8e08d882a015145eb [2017-11-28 23:59:26.028] [INFO] bot - Recieved challenge string... undefined:1 invalid action ^ SyntaxError: Unexpected token i at Object.parse (native) at Object.module.exports.safeJSON (/mnt/c/Users/USER/Desktop/poke/showdownbot-master/util.js:5:14) at Request._callback (/mnt/c/Users/USER/Desktop/poke/showdownbot-master/bot.js:115:19) at Request.self.callback (/usr/lib/nodejs/request/index.js:148:22) at emitTwo (events.js:87:13) at Request.emit (events.js:172:7) at Request. (/usr/lib/nodejs/request/index.js:896:14) at emitOne (events.js:82:20) at Request.emit (events.js:169:7) at IncomingMessage. (/usr/lib/nodejs/request/index.js:847:12)

PartyOfBardsS17 avatar Nov 29 '17 05:11 PartyOfBardsS17

Could you put this in a Markdown code block, so it's easier to read?

bb010g avatar Dec 06 '17 06:12 bb010g