"Back to the Code": timeouts in arena?

My not very complex Scala bot which execute every turn in average 10ms got many (over 90%) timeouts (in first 5 turns) when I sumbit it to arena. Does anybody has same problems, or it’s just for me? I can successfully run it in local web ide without any issues.

Sorry. but actually exeception was thrown, and it interpreted by arena engine as ‘timeout’. And nothing in error output stream. Should insert many log messages everywhere to detect it. Maby Scala starts initializing exception classes tree when exception is thrown and this initialization takes more then 100ms…

1 Like

Hi,
Please send your code to coders@codingame.com. We’ll check why your exceptions were not displayed properly.

Thx

Hi.
Thanks for response. Today I had no time, but tomorrow I will try to prepare some sample code.

I am having the same issues with my Java bot. I didn’t get a single timeout during testing against default bot. But in the arena it is timing out every single time…

I am almost certain that this is a problem with the server rather than my code. Here is some more information to help your debugging. Most of my timeouts happen at the start of the game - first few moves. Most timeouts involve timing out of more than one player around the same time. Most of my timeouts happen in the first few games after submission (say first 30). My code run against default bots never executes for more than 50ms per turn.

You desrcibed exactly the same symptoms which I had! So now I can tell you what is wrong with your code :slight_smile: The weakest bots are crashed at first turns and then theirs coordinates become -1 -1. Probably you doesn’t handled properly this values… For me also this coordinates translated to “null” Point (because it is our of field) and then I got NullPointerException later in code -> timeout in arena.

2 Likes

Yeah, like 99% of the time, a timeout does not mean you code take more than 100ms, but an invalid ouput/ unhandled exception.

OMG that was it! Thank you so much. I am forever grateful.