Cannot save path to .exe when installing a specific game

Hi,

I’m trying to install a game, everything goes well until i have to set the path to the executable.
When I complete the installation and open “Configuration” by rightclicking the game tile, then input the
path to the .exe then click “Save” under “Game Options” i ALWAYS get the following error:

‘Data length less than expected header length.’

Traceback (most recent call last):

File “/usr/lib/python3.12/site-packages/lutris/exception_backstops.py”, line 108, in error_wrapper
return handler(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^

File “/usr/lib/python3.12/site-packages/lutris/gui/config/game_common.py”, line 688, in on_save
self.game.runner.extract_icon(self.slug)

File “/usr/lib/python3.12/site-packages/lutris/runners/wine.py”, line 1244, in extract_icon
groups = extractor.get_group_icons()
^^^^^^^^^^^^^^^^^^^^^^^^^^^

File “/usr/lib/python3.12/site-packages/lutris/util/wine/extract_icon.py”, line 81, in get_group_icons
grp_icon_dir.unpack(data)

File “/usr/lib/python3.12/site-packages/pefile.py”, line 1026, in unpack
raise PEFormatError(“Data length less than expected header length.”)

pefile.PEFormatError: ‘Data length less than expected header length.’

Can someone help me with this?

OS: Arch 6.9.1-arch1-2

Thanks.

1 Like

Hi,
I can’t reproduce this on Lutris 5.17, using distro supplied Python ~3.10, but I’m only guessing at what you are doing (created wine prefix, installed something, added it as a game in Lutris and pointed it at an EXE in the prefix) so could you please supply a few steps?

Checked your Lutris version? Are all scripted installs broken too? Tried using custom images?

Same problem, looks like a bug when Lutris is trying to get the exe icon. To reproduce get exe’s here, Ja2+fix & Ja2+ai

Related is when you point it to a lnk it gives "DOS Header magic not found.’

1 Like

Can get around it by manually editing the relevant yml file in /home/user/.config/lutris/games/ with a text editor