rfvgyhn / min-ed-launcher

Minimal Elite Dangerous Launcher
MIT License
251 stars 9 forks source link

konsole not found (Flatpak Steam/Sandboxing Issue?) #113

Open Tropingenie opened 11 months ago

Tropingenie commented 11 months ago

Describe the bug/error

Summary

MinEdLauncher does not run when using a terminal emulator.

Report

With this combination, slightly modifying the suggested launch options konsole -e ./MinEdLauncher %command% /autorun /autoquit /edo I am seeing "nothing" occur. Unable to find the specified log files (still have a hard time navigating the sandbox directories), I ran Steam using Konsole to capture the logs there. I noticed the error: konsole: command not found though I am not experienced enough with Linux to know why. My suspicion is the sandbox since I run the Flatpak version of Steam.

I found the sandboxed .local later, but there are no logs in state/min-ed-launcher (since it never runs). When I run in bash (i.e. with no terminal emulator, using launch options ./MinEdLauncher %command% /autorun /autoquit /edo). Running in bash does launch the game, but is not the advised flow hence why I am making this report.

Debug log

Steam Logs

bin/sh\0-c\0konsole -e ./MinEdLauncher /home/pon/.var/app/com.valvesoftware.Steam/.local/share/Steam/ubuntu12_32/reaper SteamLaunch AppId=359320 -- /home/pon/.var/app/com.valvesoftware.Steam/.local/share/Steam/ubuntu12_32/steam-launch-wrapper -- '/p/SteamApps/SteamLibrary/steamapps/common/SteamLinuxRuntime_sniper'/_v2-entry-point --verb=waitforexitandrun -- '/p/SteamApps/SteamLibrary/steamapps/common/Proton 8.0'/proton waitforexitandrun  '/p/SteamApps/SteamLibrary/steamapps/common/Elite Dangerous/EDLaunch.exe' /Steam /novr /autorun /autoquit /edo\0
...
ERROR: ld.so: object '/home/pon/.var/app/com.valvesoftware.Steam/.local/share/Steam/ubuntu12_32/gameoverlayrenderer.so' from LD_PRELOAD cannot be preloaded (wrong ELF class: ELFCLASS32): ignored.
/bin/sh: line 1: konsole: command not found

MinEdLauncher Logs

min-ed-launcher.log

rfvgyhn commented 11 months ago

I'm not at all familiar with flatpaks so I'm not sure what the proper fix is for this.

You can try skipping the terminal emulator, you just won't get a new window showing the launcher's output. ./MinEdLauncher %command% /autorun /autoquit /edo instead of konsole -e ./MinEdLauncher %command% /autorun /autoquit /edo. Launching the game from a terminal might fix not seeing output. Something like flatpak run com.valvesoftware.Steam -gameidlaunch 359320.

If you're able to get the launcher to launch, there's a chance you run into issues with Proton's sandbox pressure-vessel. I'm not sure how the flatpak works with that. The launcher parses path arguments to try and figure out how to properly launch the game. It might need to specifically account for how the flatpak runs things.

I'm guessing you can also map the folders the launcher uses so they don't reside inside the sandbox if you want. The launcher needs access to the following:

Tropingenie commented 11 months ago

Thanks for the reply.

You can try skipping the terminal emulator

As mentioned, though I realize I wasn't as explicit as I could have been, running in the bash using ./MinEdLauncher %command% /autorun /autoquit /edo does indeed work as expected.

Launching the game from a terminal might fix not seeing output

Assuming I understand what you mean by "not seeing output," launching from command line in Konsole using flatpak run com.valvesoftware.Steam -gameidlaunch 359320 launches the game but still does not show a live output:

pon@debian:~$ flatpak run com.valvesoftware.Steam -gameidlaunch 359320
INFO:root:https://github.com/flathub/com.valvesoftware.Steam/wiki
INFO:root:Will set XDG dirs prefix to /home/pon/.var/app/com.valvesoftware.Steam
DEBUG:root:Checking input devices permissions
WARNING:root:Missing permissions for input devices
INFO:root:Overriding TZ to Canada/Pacific
steam.sh[2]: Running Steam on org.freedesktop.platform 22.08 64-bit
steam.sh[2]: STEAM_RUNTIME is enabled automatically
setup.sh[77]: Steam runtime environment up-to-date!
steam.sh[2]: Steam client's requirements are satisfied
pon@debian:~$ 

If you're able to get the launcher to launch, there's a chance you run into issues with Proton's sandbox

On the topic of Proton's sandbox VS the Flatpak sandbox, I asked around and got a reply from Cybersol on the PTN Discord that implies this is a general issue with Konsole and Steam rather than the Flatpak sandbox that I initially suspected:

It used to work but stopped a couple of months ago when Steam and Konsole stopped playing nice together. I suspect another shell might still work but haven't tested it. You can run it without konsole but won't be able to see output or input keystrokes for things like the restart mode.

...

I thinks it something in steam sandboxing the terminal somehow. My alts use proton through the steam install and I never got that to work with min-ed-launcher either.

...

I am using the Manjaro/Arch package for steam, and it did work for me before some os/steam update a couple of months ago.

I'm guessing you can also map the folders the launcher uses so they don't reside inside the sandbox

In terms of exposing directories to the (Flatpak) sandbox, anything that uses ~/.local is successfully directed by Flatpak to ~/.var/app/com.valvesoftware.Steam/.local/ and I am seeing the config in ~/.config/min-ed-launcher. Not using forceUpdate. I am unable to verify if the config is actually being used, though; I tried putting a few programs (EDMC and EDOMH) in the settings.json but they didn't launch. Might be unrelated, I am not sure.