Catapult icon indicating copy to clipboard operation
Catapult copied to clipboard

Game crashes after updating beyond https://github.com/CleverRaven/Cataclysm-DDA/pull/72708

Open XtraButtery opened this issue 10 months ago • 4 comments

/dda/game0/data/json/ui/fatigue.json has been depreciated in favour of /dda/game0/data/json/ui/sleepiness.json having a fatigue.json file will cause the game to crash with the following error message when creating a new character:

DEBUG    : Error: Invalid enum string 'fatigue' for 'widget_var'
 FUNCTION : bool main_menu::new_character_tab()
 FILE     : src/main_menu.cpp
 LINE     : 1013
 VERSION  : cdda-experimental-2024-04-11-1603 9819962

A similar error message displays when loading a character. Manually deleting fatigue.json resolves the issue entirely.

Catapult launcher does not detect or delete depreciated files which may cause future errors.

XtraButtery avatar Apr 12 '24 10:04 XtraButtery

IIRC how updating currently works, there should be no way for a json from an earlier version to end up in there... Does it reproduce if you repeat the steps? What happens if you do a new install of just this build?

qrrk avatar Apr 12 '24 20:04 qrrk

The file was renamed(not deprecated) in https://github.com/CleverRaven/Cataclysm-DDA/pull/72708/files you shoudn't have it if you update your game normally, have you touched or edited any game files (from game0 directory) by any means? Do you have any mods that interact with fatigue json? if so those mods will break your game.

AriaMoradi avatar Apr 12 '24 22:04 AriaMoradi

I had the Kenan Modpack downloaded through Catapult Launcher and nothing else installed, so I don't believe there are any additional mods that should be causing the issue.

I'm also running Catapult on Linux which may be related.

Something I should also have perhaps noted is that rolling back (i.e., installing a version prior to the pull/release) also caused the same issue where "sleepiness.json" was retained causing the same crash.

XtraButtery avatar Apr 13 '24 10:04 XtraButtery

Additional information that may be useful: I'm running Arch Linux (actually endeavourOS but the difference is negligible), using catapult from the AUR package, and I've got the Kenan modpack. As part of my tests I deleted all mods, both manually and through catapult in two separate tests, neither of which resolved the issue so I don't think it's a mod issue based on that, but perhaps further testing could confirm otherwise. Given the affected/offending file was stored in /game0/ and not /userdata/ that would point to a Catapult issue rather than a mod issue.

Below are the in-game error messages:

image image

As mentioned deleting dda/game0/data/json/ui/fatigue.json manually resolved the error. Discussions with developers and staff in the official CDDA Discord confirmed that this file should not have been present in the game, and as it is no longer packaged/bundled with the game that this was not an issue with CDDA.

My guess is that this is a Linux issue, or possible an issue with the AUR version, and that for whatever reason Catapult is unable to remove files.

Doing a couple of additional tests I think that this is the most likely outcome given the following error message when updating earlier today:

[error] Failed to remove directory /opt/catapult-bin/dda/game0. Error code: 1.

XtraButtery avatar Apr 13 '24 13:04 XtraButtery