online-go / gtp2ogs

GTP Wrapper to allow bots to interface with the Online-Go.com Server

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Crash in long-running gtp2ogs

lightvector opened this issue · comments

I had a crash today, here is the output prior to the crash. In case this was a known bug that was fixed already between rc6 and the current release, I was running rc6.

Aug 02 04:50:08   main.ts:202          Connecting to game  55845455
Aug 02 04:50:08   Game.ts:69           [game 55845455] Connecting to game.
Aug 02 04:50:09   Game.ts:131          [game 55845455] gamedata     W   deltaupsilonmega  [19x19]  H9
Aug 02 04:50:09   Game.ts:230          [game 55845359] Opponent played o8
Aug 02 04:50:09   Game.ts:397          [game 55845359] Acquiring main bot instance
Aug 02 04:50:09   pools.ts:74          Acquiring bot for live game
Aug 02 04:50:09   pools.ts:92          Picked bot in board_size pass
Aug 02 04:50:09   Game.ts:407          [bot  91:3523719] [game 55845359] Acquired bot instance
Aug 02 04:50:09   Game.ts:462          [bot  91:3523719] Generating move for game 55845359
Aug 02 04:50:09   Game.ts:463          [game 55845359] genmove white
Aug 02 04:50:09   Bot.ts:158           [bot  91:3523719] MALKOVICH:Visits 30 Winrate 99.84% ScoreLead 11.9 ScoreStdev 6.1 (PDA 2.75) PV S12 O13 P13 N13
Aug 02 04:50:09   Game.ts:325          [game 55845359] Releasing bot(s)
Aug 02 04:50:09   Game.ts:530          [game 55845359] Playing s12 { x: 17, y: 7, text: 's12', resign: false, pass: false }
Aug 02 04:50:10   Game.ts:230          [game 55845455] Opponent played k10
Aug 02 04:50:10   Game.ts:270          [game 55845455] Waiting for opponent to finish 8 more handicap moves
Aug 02 04:50:10 ! Game.ts:214          Received move for 55845455 but move_number is invalid. 1 !== 2
Aug 02 04:50:11   Game.ts:230          [game 55845442] Opponent played e5
Aug 02 04:50:11   Game.ts:397          [game 55845442] Acquiring main bot instance
Aug 02 04:50:11   pools.ts:74          Acquiring bot for live game
Aug 02 04:50:11   pools.ts:92          Picked bot in board_size pass
Aug 02 04:50:11   Game.ts:407          [bot  91:3523719] [game 55845442] Acquired bot instance
Aug 02 04:50:11   Game.ts:462          [bot  91:3523719] Generating move for game 55845442
Aug 02 04:50:11   Game.ts:463          [game 55845442] genmove white
Aug 02 04:50:11   Bot.ts:158           [bot  91:3523719] MALKOVICH:Visits 30 Winrate 0.02% ScoreLead -62.0 ScoreStdev 15.9 (PDA 2.75) PV C2 B2 D2 E2 E3 C1
Aug 02 04:50:11   Game.ts:325          [game 55845442] Releasing bot(s)
Aug 02 04:50:11   Game.ts:530          [game 55845442] Playing c2 { x: 2, y: 17, text: 'c2', resign: false, pass: false }
Aug 02 04:50:13   Game.ts:230          [game 55845442] Opponent played b2
Aug 02 04:50:13   Game.ts:397          [game 55845442] Acquiring main bot instance
Aug 02 04:50:13   pools.ts:74          Acquiring bot for live game
Aug 02 04:50:13   pools.ts:92          Picked bot in game_id pass
Aug 02 04:50:13   Game.ts:407          [bot  91:3523719] [game 55845442] Acquired bot instance
Aug 02 04:50:13   Game.ts:462          [bot  91:3523719] Generating move for game 55845442
Aug 02 04:50:13   Game.ts:463          [game 55845442] genmove white
Aug 02 04:50:13   Game.ts:230          [game 55845359] Opponent played s11
Aug 02 04:50:13   Game.ts:397          [game 55845359] Acquiring main bot instance
Aug 02 04:50:13   pools.ts:74          Acquiring bot for live game
Aug 02 04:50:13   pools.ts:92          Picked bot in any pass
Aug 02 04:50:13   Game.ts:407          [bot  92:3523851] [game 55845359] Acquired bot instance
Aug 02 04:50:13   Bot.ts:158           [bot  92:3523851] Initializing board with boardXSize 19 boardYSize 19
Aug 02 04:50:13   Bot.ts:158           [bot  91:3523719] MALKOVICH:Visits 30 Winrate 0.02% ScoreLead -62.0 ScoreStdev 15.7 (PDA 2.75) PV D2 E2 E3 C1 C14
Aug 02 04:50:13   Game.ts:325          [game 55845442] Releasing bot(s)
Aug 02 04:50:13   Game.ts:571          [game 55845442] Min move time was  300 ms and we only took  237 ms. Waiting  63 ms before sending move
Aug 02 04:50:13   Game.ts:462          [bot  92:3523851] Generating move for game 55845359
Aug 02 04:50:13   Game.ts:463          [game 55845359] genmove white
Aug 02 04:50:13   Game.ts:530          [game 55845442] Playing d2 { x: 3, y: 17, text: 'd2', resign: false, pass: false }
Aug 02 04:50:13   Bot.ts:158           [bot  92:3523851] MALKOVICH:Visits 30 Winrate 99.85% ScoreLead 13.0 ScoreStdev 5.8 (PDA 2.75) PV A4 O13 P13
Aug 02 04:50:13   Game.ts:325          [game 55845359] Releasing bot(s)
Aug 02 04:50:13   Game.ts:530          [game 55845359] Playing a4 { x: 0, y: 15, text: 'a4', resign: false, pass: false }
Aug 02 04:50:14   Game.ts:230          [game 55845442] Opponent played e2
Aug 02 04:50:14   Game.ts:397          [game 55845442] Acquiring main bot instance
Aug 02 04:50:14   pools.ts:74          Acquiring bot for live game
Aug 02 04:50:14   pools.ts:92          Picked bot in game_id pass
Aug 02 04:50:14   Game.ts:407          [bot  91:3523719] [game 55845442] Acquired bot instance
Aug 02 04:50:14   Game.ts:462          [bot  91:3523719] Generating move for game 55845442
Aug 02 04:50:14   Game.ts:463          [game 55845442] genmove white
Aug 02 04:50:14   Bot.ts:158           [bot  91:3523719] MALKOVICH:Visits 30 Winrate 0.02% ScoreLead -61.6 ScoreStdev 16.2 (PDA 2.75) PV E3 C1 Q5 R4
Aug 02 04:50:14   Game.ts:325          [game 55845442] Releasing bot(s)
Aug 02 04:50:14   Game.ts:571          [game 55845442] Min move time was  300 ms and we only took  203 ms. Waiting  97 ms before sending move
Aug 02 04:50:14   Game.ts:530          [game 55845442] Playing e3 { x: 4, y: 16, text: 'e3', resign: false, pass: false }
Aug 02 04:50:16   Game.ts:230          [game 55845455] Opponent played k10
Aug 02 04:50:16   Game.ts:270          [game 55845455] Waiting for opponent to finish 7 more handicap moves
Aug 02 04:50:16   Game.ts:230          [game 55845442] Opponent played d1
Aug 02 04:50:16   Game.ts:397          [game 55845442] Acquiring main bot instance
Aug 02 04:50:16   pools.ts:74          Acquiring bot for live game
Aug 02 04:50:16   pools.ts:92          Picked bot in game_id pass
Aug 02 04:50:16   Game.ts:407          [bot  91:3523719] [game 55845442] Acquired bot instance
Aug 02 04:50:16   Game.ts:462          [bot  91:3523719] Generating move for game 55845442
Aug 02 04:50:16   Game.ts:463          [game 55845442] genmove white
Aug 02 04:50:17   Bot.ts:158           [bot  91:3523719] MALKOVICH:Visits 30 Winrate 0.02% ScoreLead -61.8 ScoreStdev 15.8 (PDA 2.75) PV C12 E6 E7
Aug 02 04:50:17   Game.ts:325          [game 55845442] Releasing bot(s)
Aug 02 04:50:17   Game.ts:571          [game 55845442] Min move time was  300 ms and we only took  262 ms. Waiting  38 ms before sending move
Aug 02 04:50:17   Game.ts:530          [game 55845442] Playing c12 { x: 2, y: 7, text: 'c12', resign: false, pass: false }
Aug 02 04:50:17   Game.ts:230          [game 55845455] Opponent played k4
Aug 02 04:50:17   Game.ts:270          [game 55845455] Waiting for opponent to finish 6 more handicap moves
Aug 02 04:50:18   Game.ts:230          [game 55845455] Opponent played q4
Aug 02 04:50:18   Game.ts:270          [game 55845455] Waiting for opponent to finish 5 more handicap moves
Aug 02 04:50:19   Game.ts:230          [game 55845442] Opponent played c14
Aug 02 04:50:19   Game.ts:397          [game 55845442] Acquiring main bot instance
Aug 02 04:50:19   pools.ts:74          Acquiring bot for live game
Aug 02 04:50:19   pools.ts:92          Picked bot in game_id pass
Aug 02 04:50:19   Game.ts:407          [bot  91:3523719] [game 55845442] Acquired bot instance
Aug 02 04:50:19   Game.ts:462          [bot  91:3523719] Generating move for game 55845442
Aug 02 04:50:19   Game.ts:463          [game 55845442] genmove white
Aug 02 04:50:19   Game.ts:670          [game 55845403] Game over.   Result: W+R  W
Aug 02 04:50:19   Game.ts:694          [game 55845403] Starting disconnect Timeout in Game 55845403 gameOver()
Aug 02 04:50:19   main.ts:173          game 55845403 is now finished
Aug 02 04:50:19   Bot.ts:158           [bot  91:3523719] MALKOVICH:Visits 30 Winrate 0.02% ScoreLead -62.1 ScoreStdev 16.2 (PDA 2.75) PV E12 E6 E7 D7
Aug 02 04:50:19   Game.ts:325          [game 55845442] Releasing bot(s)
Aug 02 04:50:19   Game.ts:571          [game 55845442] Min move time was  300 ms and we only took  294 ms. Waiting  6 ms before sending move
Aug 02 04:50:19   Game.ts:530          [game 55845442] Playing e12 { x: 4, y: 7, text: 'e12', resign: false, pass: false }
Aug 02 04:50:19   Game.ts:230          [game 55845455] Opponent played q10
Aug 02 04:50:19   Game.ts:270          [game 55845455] Waiting for opponent to finish 4 more handicap moves
Aug 02 04:50:20   main.ts:213          Disconnecting from game  55845403
Aug 02 04:50:20   Game.ts:325          [game 55845403] Releasing bot(s)
Aug 02 04:50:20   Game.ts:639          [game 55845403] Disconnecting from game.
Aug 02 04:50:20   Game.ts:230          [game 55845455] Opponent played q16
Aug 02 04:50:20   Game.ts:270          [game 55845455] Waiting for opponent to finish 3 more handicap moves
Aug 02 04:50:21   Game.ts:230          [game 55845359] Opponent played o13
Aug 02 04:50:21   Game.ts:397          [game 55845359] Acquiring main bot instance
Aug 02 04:50:21   pools.ts:74          Acquiring bot for live game
Aug 02 04:50:21   pools.ts:92          Picked bot in game_id pass
Aug 02 04:50:21   Game.ts:407          [bot  92:3523851] [game 55845359] Acquired bot instance
Aug 02 04:50:21   Game.ts:230          [game 55845455] Opponent played k16
Aug 02 04:50:21   Game.ts:270          [game 55845455] Waiting for opponent to finish 2 more handicap moves
Aug 02 04:50:21   Game.ts:462          [bot  92:3523851] Generating move for game 55845359
Aug 02 04:50:21   Game.ts:463          [game 55845359] genmove white
Aug 02 04:50:21   main.ts:224          Status: playing 0 blitz, 6 live, 0 correspondence games
Aug 02 04:50:21   main.ts:227          Available bots: 1/2 main, 0/0 ending, 0/0 opening
Aug 02 04:50:22   Bot.ts:158           [bot  92:3523851] MALKOVICH:Visits 30 Winrate 99.78% ScoreLead 13.8 ScoreStdev 6.2 (PDA 2.75) PV P13 N13 N12 P14 O14 Q13
P12
Aug 02 04:50:22   Game.ts:325          [game 55845359] Releasing bot(s)
Aug 02 04:50:22   Game.ts:530          [game 55845359] Playing p13 { x: 14, y: 6, text: 'p13', resign: false, pass: false }
Aug 02 04:50:22   Game.ts:230          [game 55845442] Opponent played e17
Aug 02 04:50:22   Game.ts:397          [game 55845442] Acquiring main bot instance
Aug 02 04:50:22   pools.ts:74          Acquiring bot for live game
Aug 02 04:50:22   pools.ts:92          Picked bot in game_id pass
Aug 02 04:50:22   Game.ts:407          [bot  91:3523719] [game 55845442] Acquired bot instance
Aug 02 04:50:22   Game.ts:462          [bot  91:3523719] Generating move for game 55845442
Aug 02 04:50:22   Game.ts:463          [game 55845442] genmove white
Aug 02 04:50:23   Bot.ts:158           [bot  91:3523719] MALKOVICH:Visits 30 Winrate 0.03% ScoreLead -58.5 ScoreStdev 15.5 (PDA 2.75) PV E6 G12 F11
Aug 02 04:50:23   Game.ts:325          [game 55845442] Releasing bot(s)
Aug 02 04:50:23   Game.ts:530          [game 55845442] Playing e6 { x: 4, y: 13, text: 'e6', resign: false, pass: false }
Aug 02 04:50:24   Game.ts:230          [game 55845443] Opponent played m11
Aug 02 04:50:24   Game.ts:397          [game 55845443] Acquiring main bot instance
Aug 02 04:50:24   pools.ts:74          Acquiring bot for live game
Aug 02 04:50:24   pools.ts:92          Picked bot in any pass
Aug 02 04:50:24   Game.ts:407          [bot  91:3523719] [game 55845443] Acquired bot instance
Aug 02 04:50:24   Bot.ts:158           [bot  91:3523719] Initializing board with boardXSize 13 boardYSize 13
Aug 02 04:50:24   Game.ts:462          [bot  91:3523719] Generating move for game 55845443
Aug 02 04:50:24   Game.ts:463          [game 55845443] genmove white
Aug 02 04:50:24   Game.ts:230          [game 55845455] Opponent played d10
Aug 02 04:50:24   Game.ts:270          [game 55845455] Waiting for opponent to finish 1 more handicap moves
Aug 02 04:50:24   Bot.ts:158           [bot  91:3523719] MALKOVICH:Visits 30 Winrate 0.09% ScoreLead -14.6 ScoreStdev 5.2 (PDA 1.88) PV M4 M5 M3 G9 F9
Aug 02 04:50:24   Game.ts:325          [game 55845443] Releasing bot(s)
Aug 02 04:50:24   Game.ts:530          [game 55845443] Playing m4 { x: 11, y: 9, text: 'm4', resign: false, pass: false }
Aug 02 04:50:25   Game.ts:230          [game 55845455] Opponent played d16
Aug 02 04:50:25   Game.ts:397          [game 55845455] Acquiring main bot instance
Aug 02 04:50:25   pools.ts:74          Acquiring bot for live game
Aug 02 04:50:25   pools.ts:92          Picked bot in board_size pass
Aug 02 04:50:25   Game.ts:407          [bot  92:3523851] [game 55845455] Acquired bot instance
Aug 02 04:50:25   Game.ts:462          [bot  92:3523851] Generating move for game 55845455
Aug 02 04:50:25   Game.ts:463          [game 55845455] genmove white
Aug 02 04:50:25   Bot.ts:202           [bot  92:3523851] ? Handicap placement is invalid
Aug 02 04:50:25   Bot.ts:205           [bot  92:3523851]

Aug 02 04:50:25 ! source-map-support.js:448 UnhandledPromiseRejection: This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). The promise rejected with the reason "Handicap placement is invalid".

The things that appear to be weird are that:

Aug 02 04:50:10 ! Game.ts:214          Received move for 55845455 but move_number is invalid. 1 !== 2

And then presumably the gtp2ogs script sent a bad handicap placement for some reason to the bot, due to getting into some weird state? The bot responds with "Handicap placement is invalid", and then this apparently was not gracefully handled. If you look at the game, the game is just an ordinary free-placement where the player chose to place their 9 stones on all the star points, something that should happen all the time. So maybe there's two issues here - what caused the original getting into a weird state, (possibly related to getting a move for 55845455 unexpectedly), and then gracefully handling the bad situation rather than crashing the whole script once the bot reports that it's been fed something bad.

I didn't have GTP command logging enabled on the bot's side of things this time, so sadly I don't know exactly what was invalid about the handicap placement that was sent. Maybe a duplicated stone or something? That seems like the most likely kind of thing that might happen if the script's unexpected receipt of a move or some other weirdness caused it to reprocess things maybe? I haven't looked at the code.

This issue has been marked stale and will be closed soon without further activity. To keep the issue open, please respond to the comment to keep the discussion going.