#993705 freeorion: 'PythonAI failed to initialize' when starting singleplayer game with AI

Package:
freeorion
Source:
freeorion
Description:
turn-based space empire and galactic conquest game
Submitter:
Date:
2025-02-09 06:27:01 UTC
Severity:
normal
Tags:
#993705#5
Date:
2021-09-05 01:36:44 UTC
From:
To:
Dear Maintainer,

   * What led up to the situation?
   In the unstable version, starting a game with AI fails to allow a
   game to start.
   * What exactly did you do (or not do) that was effective (or
     ineffective)?
     I attempted recompiling the game and researching the bug to see if
     I was missing a dependency, however this resulted in nothing
     worthwhile occouring.
   * What was the outcome of this action?
   'PythonAI failed to initialize' in console and "The connection to the
   server has been lost" as an error from the game
   * What outcome did you expect instead?
   I expected a game to start with AI enabled

#993705#10
Date:
2021-09-05 14:32:02 UTC
From:
To:
Hello,

The single player mode with AI works for me. I noticed you are using Devuan not
Debian. Can you reproduce the problem in Debian unstable and tell me the exact
steps to reproduce the problem?

Regards,

Markus

#993705#17
Date:
2021-09-05 22:16:52 UTC
From:
To:
I opted to try to reproduce the problem on both a unstable Devuan and Debian VM and it worked as intended. It's likely that there is something up with my system then that's causing this problem. If I can figure out what in specific it is, I'll let you know in case its an incompatible package.

Sep 5, 2021, 09:32 by apo@debian.org:

#993705#22
Date:
2021-09-05 22:38:27 UTC
From:
To:
I should have looked at this first, but the game's log files for both AI and world generation show some errors in relation to importing of a module (specifically on line 150 of CommonFramework.cpp). I'm not too savvy with C++, but I do know that something is messed up with how its importing "common.configure_logging". Judging by their documentation on the python directory, common.configure_logging is supposed to be imported from a folder above turn_events.py <https://github.com/freeorion/freeorion/blob/84c2e2e820d0ec55d2bd1f8f903398bab6cdf0d9/default/python/turn_events/turn_events.py>, however isn't (https://github.com/freeorion/freeorion/tree/84c2e2e820d0ec55d2bd1f8f903398bab6cdf0d9/default/python).
Sep 5, 2021, 17:16 by joyfulmange@tutanota.com:

#993705#27
Date:
2025-02-09 06:17:55 UTC
From:
To:
Hi!

Could you try again when 0.5.1 release will be published in repository
and share AI_1.log and freeoriond.log files?