Hello everyone!
On my system, Lutris says it could not find an executable if it is located on a mounted non-system drive. The game starts OK if I cd into its directory and run it through Wine. The game starts OK through Lutris if it is located on a system drive.
I don’t know if it is a bug or not. I hope someone here could help me resolve my problem. Below, I describe the problem in details.
Required:
- Lutris 0.5.18.
- The game is installed on external (non-system) drive. This drive is connected to the system.
Steps I do to reproduce:
- mount /dev/disk/by-uuid/uuid /mnt/uuid.
- Launch Lutris.
- Press Add Game.
- Select Add locally installed game.
- Enter game’s Name.
- Select option Wine in Runner.
- Into the field Executable, manually type the absolute path to the game’s executable: /mnt/uuid/.wine/drive_c/…/…exe.
- Into the field Working directory, manually type the absolute path to the executable’s directory: /mnt/uuid/.wine/drive_c/…
- Press Save.
- Select added game and press Play.
Result:
Error message appears: “Lutris has encountered an error. The file … could not be found”. See screenshot.
Why I type the paths manually:
If I select the executable through three dots option, the graphical file finder appears. The mounted directory and its contains are perfectly visible there, but after selecting an executable/path that way, the actual value of the field looks like some directory under /run: /run/user/1000/doc/…
Log output of lutris -d is in the replies. There is a line #21 with the same error message as in the graphical interface. There are weird #10-#15 lines above it, but I think they do not matter because they appear as I just move from the Game info tab to the Game options tab.
INFO 2024-12-16 12:35:24,538 [application.do_command_line:480]:Starting Lutris 0.5.18
INFO 2024-12-16 12:35:24,568 [startup.run_all_checks:120]:“card1” is AMD Radeon RX 7600 (1002:7480 1458:240b amdgpu) Driver 24.3.1
DEBUG 2024-12-16 12:35:24,724 [path_cache._update_missing_games:114]:Checking for missing games
DEBUG 2024-12-16 12:35:24,754 [api.check_stale_runtime_versions:52]:Modified at Sun 15 Dec 2024 22:52:38 , will update after Mon 16 Dec 2024 04:52:38
DEBUG 2024-12-16 12:35:24,754 [http._request:88]:GET https://lutris.net/api/runtimes/versions?pci_ids=1002:7480%201458:240B
DEBUG 2024-12-16 12:35:24,992 [lutriswindow.create_runtime_updater_cb:1358]:Runtime up to date
DEBUG 2024-12-16 12:35:27,049 [application.show_window:396]:Showing window AddGamesWindow{‘parent’: <lutriswindow.LutrisWindow object at 0x7cbfda7cdac0 (LutrisWindow at 0x64f6c944d330)>}
DEBUG 2024-12-16 12:35:28,216 [application.on_app_window_destroyed:421]:Removed window AddGamesWindow{‘parent’: <lutriswindow.LutrisWindow object at 0x7cbfda7cdac0 (LutrisWindow at 0x64f6c944d330)>}
INFO 2024-12-16 12:35:55,042 [game_common._switch_runner:600]:Creating new configuration with runner wine
WARNING 2024-12-16 12:35:56,296 [runner.game_config:92]:Accessing game config while runner wasn’t given one.
WARNING 2024-12-16 12:35:56,296 [runner.game_config:92]:Accessing game config while runner wasn’t given one.
ERROR 2024-12-16 12:35:56,296 [wine.game_exe:655]:The game doesn’t have an executable
WARNING 2024-12-16 12:35:56,297 [runner.game_config:92]:Accessing game config while runner wasn’t given one.
WARNING 2024-12-16 12:35:56,297 [runner.game_config:92]:Accessing game config while runner wasn’t given one.
ERROR 2024-12-16 12:35:56,297 [wine.game_exe:655]:The game doesn’t have an executable
DEBUG 2024-12-16 12:37:48,854 [http._request:88]:GET https://lutris.net/api/games/the-binding-of-isaac-rebirth
DEBUG 2024-12-16 12:37:48,862 [game.save:454]:Saving The Binding of Isaac Rebirth (wine) with config ID the-binding-of-isaac-rebirth-1734349068
DEBUG 2024-12-16 12:37:48,862 [config.save:227]:Saving LutrisConfig(level=game, game_config_id=the-binding-of-isaac-rebirth-1734349068, runner=wine) config to /home/iskander/.var/app/net.lutris.Lutris/data/lutris/games/the-binding-of-isaac-rebirth-1734349068.yml
ERROR 2024-12-16 12:37:48,890 [game.id:150]:The game ‘The Binding of Isaac Rebirth’ has no ID, it is not stored in the database.
DEBUG 2024-12-16 12:37:48,904 [path_cache.add_to_path_cache:47]:Adding The Binding of Isaac Rebirth (wine) to path cache
ERROR 2024-12-16 12:38:18,814 [exception_backstops.wrapper:34]:The Binding of Isaac Rebirth (wine) has encountered an error: The file /mnt/0818d707-9320-40ee-b59f-9b960e7ad612/.wine/drive_c/GOG Games/The Binding of Isaac Rebirth/isaac-ng_launcher.exe could not be found
Traceback (most recent call last):
File “/app/lib/python3.12/site-packages/lutris/exception_backstops.py”, line 29, in wrapper
result = function(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^
File “/app/lib/python3.12/site-packages/lutris/game.py”, line 672, in configure_game
gameplay_info = self.get_gameplay_info(launch_ui_delegate)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File “/app/lib/python3.12/site-packages/lutris/game.py”, line 611, in get_gameplay_info
gameplay_info = self.runner.play()
^^^^^^^^^^^^^^^^^^
File “/app/lib/python3.12/site-packages/lutris/runners/wine.py”, line 1223, in play
raise MissingGameExecutableError(filename=game_exe)
lutris.exceptions.MissingGameExecutableError: The file /mnt/0818d707-9320-40ee-b59f-9b960e7ad612/.wine/drive_c/GOG Games/The Binding of Isaac Rebirth/isaac-ng_launcher.exe could not be found
DEBUG 2024-12-16 12:38:18,814 [game.stop_game:894]:The Binding of Isaac Rebirth (wine) has run for 0 seconds
WARNING 2024-12-16 12:38:18,814 [game.stop_game:896]:The game has run for a very short time, did it crash?
DEBUG 2024-12-16 12:38:18,814 [game.stop_game:906]:Playtime: Never played
DEBUG 2024-12-16 12:38:18,814 [application.on_game_stopped:793]:Removing 1 from running IDs
INFO 2024-12-16 12:38:55,876 [application.do_shutdown:1049]:Shutting down Lutris
Are you using Lutris Flatpak version?
Flatpak apps have restricted access to your home and system folders/files.
Install Flatseal then add access to your hard drive in “other files” section:
Thank you very much. You were right, Flatpak apps have restricted access to system’s directory indeed. I just looked into what these directories actually are. Apparently, there are very few of them. I confirmed that information on official Flatpak resourse [1]. There was --filesystem option mentioned, which grants an app the access to specific place of your system. So a read flatpak-run(1) man page to find out how to use it. Apparently, there are Flatpak metadata files (flatpak-metadata(1)) for each app, and the option is already set there. My Lutris’ metadata file was here:
$HOME/.local/share/flatpak/app/net.lutris.Lutris/current/active/metadata
In it, there was a statement indeed:
filesystems=home;/media;/run/media;~/.config/MangoHud:ro;xdg-run/gamescope-0:ro;~/.var/app/com.valvesoftware.Steam:ro;xdg-data/umu:create;
So while my Lutris did not have an access to /mnt directory indeed, it had an access to, say, /media directory. So I just changed the mountpoint of my drive from /mnt/uuid to /media/uuid, and the game starts now. Also I can select the executable’s path via graphical interface, not typing it.
[1] Sandbox Permissions - Flatpak documentation