Closed metinc closed 1 month ago
Thanks for your work on this.
The solution looks good but I'm worried about potentially leaving the temp dir as it would lead to steam uninstallation not working properly. We could try an approach where cleanup polls the locked state of eldenring.exe (e.g. every 3 seconds) and proceeds when the lock has ceased.
In any case, I'd like to have this tested on Linux before merging.
@gurrgur I understand your concerns regarding the er-patcher-tmp
folder not being deleted. I wasn't aware that this issue was causing the Steam uninstall to no longer work. I have now adjusted my pull request accordingly. If os.remove()
fails because eldenring.exe
has not been unlocked yet, a retry will be executed every 3 seconds. If a different error occurs, no retry will be performed. In any case, rmtree()
will be executed afterward.
Additionally, I have now installed Arch Linux in a dual boot setup. I will test the changes under Linux and provide feedback.
Thanks for the update! LGTM
Oh and I just tested running seamless coop on linux and it starts up just fine!
env WINE_FULLSCREEN_FSR=1 python er-patcher -ucvs --rate 120 -x ersc_launcher.exe -- %command%
If you pass an
--executable
arg like when playing the Seamless Co-op mod Elden Ring does crash. The reason issubprocess.run()
waits for the passed executable likeersc_launcher.exe
to finish but it does not wait foreldenring.exe
to finish. The Python script is unaware ofeldenring.exe
since it was executed byersc_launcher.exe
. Thenrmtree()
is called and deletes the patchedeldenring.exe
while it is running. This PR solves this by checking ifeldenring.exe
can be accessed. If it is locked it won't be deleted. The behavior remains unchanged if--executable
is not passed. I tested this on Windows 11. Would be great if someone can test it on Linux aswell.Fixes #54 Fixes #60 Fixes #61