Ikabot-Collective / ikabot

A Python-based bot designed for automating tasks in the game Ikariam
https://discord.com/invite/3hyxPRj
MIT License
90 stars 62 forks source link

Resources transporting fails #204

Open susikaman opened 6 months ago

susikaman commented 6 months ago

Bug explanation

Any function that uses sendResources, occationally returns this error. It seems to happen only with specific accounts or towns. I only encounter this error on some accounts, but not most. Could be due to an Ikariam bug, not sure why it happens since I'm able to send resources manually.

Error in:

Transport resources to upload building

Cause: Traceback (most recent call last): File "ikabot\function\constructionList.py", line 315, in sendResourcesNeeded File "ikabot\helpers\planRoutes.py", line 139, in executeRoutes File "ikabot\helpers\planRoutes.py", line 87, in sendGoods KeyError: 0

Operating System

Windows

Ikabot installation

I downloaded the pre-built Windows binary

Ikabot version

Latest

Python version

3.11.3

susikaman commented 6 months ago

I strongly believe that this is due to a bug in Ikariam, when some towns are simply not able to use any trade ships for some reason. This only seems to happen in specific towns and accounts, which is really weird. If someone has faced the same issue, please tell.

ikagod commented 6 months ago

It would be nice if you posted more information about this error instead of just the traceback. The improved logging system allows you to append the last five requests and automatically upload them to pastebin (albeit in compressed form). If you did this maybe we could go though the requests / responses and see what caused this. Also the time at which this error occurred is important. If it happened at about 05 am your time, it's probably caused by the Ikariam world backup. There is a lot more data in the logs that could be useful for troubleshooting this.

susikaman commented 6 months ago

It would be nice if you posted more information about this error instead of just the traceback. The improved logging system allows you to append the last five requests and automatically upload them to pastebin (albeit in compressed form). If you did this maybe we could go though the requests / responses and see what caused this. Also the time at which this error occurred is important. If it happened at about 05 am your time, it's probably caused by the Ikariam world backup. There is a lot more data in the logs that could be useful for troubleshooting this.

I have confirmed that when this error occurs, it's not possible to set transport ships even manually from the browser. And that only happens for the specific town. I'll leave this here in case someone else runs into the problem, and has some more knwledge of it.