Stellaris

Stellaris

Stellaris Dashboard
stellarisdashboard.exe exits after "Warning: Game xx could not be found in database!"
This is the Traceback and the Warning:

2019-01-06 12:44:40,354 - stellarisdashboard.visualization_data - WARNING - Warning: Game fivestarscollective_-477761590 could not be found in database! Traceback (most recent call last): File "stellarisdashboard\__main__.py", line 29, in <module> File "stellarisdashboard\__main__.py", line 21, in main File "stellarisdashboard\cli.py", line 142, in f_monitor_saves File "stellarisdashboard\visualization_data.py", line 415, in get_current_execution_plot_data File "stellarisdashboard\visualization_data.py", line 669, in update_with_new_gamestate File "stellarisdashboard\models.py", line 311, in get_gamestates_since File "lib\site-packages\sqlalchemy\orm\query.py", line 2960, in one sqlalchemy.orm.exc.NoResultFound: No row was found for one() [21516] Failed to execute script __main__
< >
Showing 1-9 of 9 comments
blubblubblobb  [developer] 6 Jan, 2019 @ 6:40am 
Hi, thanks for the bug report and for already including the error info!

Are you using any mods? And if you are, could you check if the dashboard works with a new vanilla game? (disable all other mods in the Stellaris launcher and start a new game, make a save and check if the dashboard works)

Can you check if there is a file called "fivestarscollective_-477761590.db" in the "output\db" folder?

I think there is probably some error happening while reading the save file, which causes a failure in initializing the database correctly. Later, when you try to view the dashboard, the program tries to read the bad database and crashes. Is there any similar looking traceback message in the earlier output of the program?
So. Here's my report.
It works. Occasionally. Something is definitely happening and screwing things up in some way.

I am using quite a few mods, so that's probably the underlying issue. It doesn't explain the sporadic nature of the issue, though so that's still weird.

I had already check the output/db directory to see if the file existed before your reply. I examined the sqlite database and found that it didn't contain a record in the gametable table. I had also removed the folder and tried again a few times, in various combinations. At some point the import worked and the record was created correctly.

Now I have a dashboard, but something is still going wrong somewhere because I only have 2 game states saved (several years apart), but I have kept the program running and it has gone through multiple save files that somehow weren't imported correctly as game states. I also have several issues with the data on the charts I can see as some don't have all the empires I would expect to see while others do.

That's about it.
blubblubblobb  [developer] 7 Jan, 2019 @ 5:36am 
Ok if it works sometimes, then I think it is probably a mod issue.

If you want, you can email one or two save files that do not work to blubblubblobb at gmail dot com. I generally don't guarantee mod compatibility, but if the issue is simple to diagnose and fix, I will do it.
blubblubblobb  [developer] 7 Jan, 2019 @ 5:44am 
Since you already had a look at the database, I will explain the problem in more detail:

The gametable stores the Game object, which contains general information about game settings, and references to all the important data, so it is the root of the data model.

If the first save encountered by the program is broken, then the database file (containing table headers etc.) is created, but in this case generally nothing gets written to the database to avoid adding bad or inconsistent data.

Since a separate database is created for each game, the assumption in the code is that there should be exactly one row in the gametable. However, when loading from the database of the game with the save that doesn't work, the gametable is empty, which ultimately causes the crash.
Last edited by blubblubblobb; 7 Jan, 2019 @ 7:59am
The most common error I'm seeing is "stellarisdashboard.timeline - ERROR - 'NoneType' object has no attribute 'planet_id'".
blubblubblobb  [developer] 8 Jan, 2019 @ 11:54pm 
Hi, sorry for the late reply. This issue could come from multiple places in the code. If you want me to take a closer look, I am going to need a save file to diagnose the problem. You can sen them to "blubblubblobb at gmail dot com"
Last edited by blubblubblobb; 8 Jan, 2019 @ 11:55pm
Sure, I have a new savegame I'm messing around with chock full of mods. You can take a look at that, I'll send it right over.
blubblubblobb  [developer] 10 Jan, 2019 @ 4:57am 
Thanks, I got your save file. At the moment, I'm pretty busy IRL but I will take a look as soon as I can.
blubblubblobb  [developer] 24 Jan, 2019 @ 12:19pm 
Hi, I think I fixed the issue. At least, the save file that you sent me works fine on my system now. There was an error in the HTML template which assumed that each ruled_empire event had a planet associated with it which was somehow not the case in your game.

I am currently rewriting a big part of the program, so it will take a little while to make a proper release. However, when it is done, the program should hopefully be much better at handling small errors like this without crashing.
< >
Showing 1-9 of 9 comments
Per page: 1530 50