Improvement for LoL installer script

I think I found a way to improve install scripts. Trying to install LoL failed because I don’t have the correct wine version installed. Lutris can do this, but doesn’t ask me. Nor does it say that this is the error for my install. Instead it outputs this error during the “visual c++ 2005” install:

FileNotFoundError(2, 'No such file or directory')

It would have been faster/easier for me if the GUI told me I didn’t have the compatible wine version. This is how I found out what was the problem, by running lutris via the command line:

(lutris:13170): Gtk-WARNING **: Theme parsing error: gtk.css:30:35: '/*' in comment block

(lutris:13170): Gtk-WARNING **: Theme parsing error: gtk.css:30:110: '/*' in comment block

(lutris:13170): Gtk-WARNING **: Theme parsing error: gtk.css:31:36: '/*' in comment block

(lutris:13170): Gtk-WARNING **: Theme parsing error: gtk.css:31:77: '/*' in comment block
INFO     2017-03-15 13:00:36,225 [desktopapps]:Setting League of Legends as installed
WARNING  2017-03-15 13:00:51,108 [wine]:No wine version staging-1.9.21-i386 found, falling back to system
INFO     2017-03-15 13:00:51,112 [interpreter]:Downloading file 1 of 1
ERROR    2017-03-15 13:00:52,427 [system]:Could not run command ['/home/USERNAME/.local/share/lutris/runners/wine/staging-1.9.21-i386/bin/wineboot']: [Errno 2] No such file or directory: '/home/USERNAME/.local/share/lutris/runners/wine/staging-1.9.21-i386/bin/wineboot'
ERROR    2017-03-15 13:00:57,435 [wine]:No user.reg found after prefix creation. Prefix might not be valid
INFO     2017-03-15 13:00:57,435 [wine]:win32 Prefix created in /home/USERNAME/.wine32/drive_c/league-of-legends
ERROR    2017-03-15 13:00:57,435 [wineregistry]:Unexisting registry %s
ERROR    2017-03-15 13:00:57,435 [jobs]:Error while completing task <bound method CommandsMixin.task of <lutris.installer.interpreter.ScriptInterpreter object at 0x7f3264ce8668>>: [Errno 2] No such file or directory: '/home/USERNAME/.wine32/drive_c/league-of-legends/user.reg'
<class 'FileNotFoundError'> [Errno 2] No such file or directory: '/home/USERNAME/.wine32/drive_c/league-of-legends/user.reg'
  File "/usr/lib/python3.6/site-packages/lutris/util/jobs.py", line 29, in target
    result = self.function(*args, **kwargs)
  File "/usr/lib/python3.6/site-packages/lutris/installer/commands.py", line 328, in task
    thread = task(**data)
  File "/usr/lib/python3.6/site-packages/lutris/runners/wine.py", line 161, in winetricks
    wine_path=winetricks_path, arch=arch, args=args, config=config)
  File "/usr/lib/python3.6/site-packages/lutris/runners/wine.py", line 120, in wineexec
    create_prefix(prefix, wine_path=wine_bin, arch=arch)
  File "/usr/lib/python3.6/site-packages/lutris/runners/wine.py", line 96, in create_prefix
    prefix_manager.setup_defaults()
  File "/usr/lib/python3.6/site-packages/lutris/util/wineprefix.py", line 16, in setup_defaults
    self.override_dll("winemenubuilder.exe", "")
  File "/usr/lib/python3.6/site-packages/lutris/util/wineprefix.py", line 49, in override_dll
    self.set_registry_key(key, dll, mode)
  File "/usr/lib/python3.6/site-packages/lutris/util/wineprefix.py", line 35, in set_registry_key
    registry.save()
  File "/usr/lib/python3.6/site-packages/lutris/util/wineregistry.py", line 143, in save
    with open(path, 'w') as registry_file:

Afterwards I:

  • Manager Runners > Wine > Manage Versions > Check “staging-1.9.21 (i386)” (Also I don’t know why it says i386 when I’m on a 64bit, but I assume it is because the LoL installer is 32bit?)
  • Then I removed League of Legends from my library (This sometimes shows up, but sometimes does not when failing to install from the site).
  • Went back to lutris.net LoL page and clicked install

This time at the Visual C++ 2005 step the “Wine Mono Installer” popped up, I clicked install. It does the rest of it’s steps without a hitch and finishes the installation successfully.

Another note, in case it helps figure out why some people have this problem and not others, if it’s not the wine version issue, it may be that I installed to a shared “wine 32bit” directory. Just trying to help with as much information as possible. I’m not program-savvy, so I hope this helps the developer(s) improve this app. It’s thus far an incredible achievement to find a page and just click install and have it work on your computer. I love lutris! Thank you.

The “File not found” error is now fixed in Lutris 0.4.6 (released today). There was a bug that prevented specific wine versions to be downloaded by the installer.

I’ve made a couple changes and LoL seems to be running fine (at least the launcher, the game is still downloading).

I tried updating the launcher and it crashed a lot so I reverted back to the legacy one but apparently some people have had success with the new one.

I tried the classic/legacy launcher as yourself, however I cannot log in. The internet seems to not be working at the log in screen and I get a “Did Not Receive Response from Server; Retrying (Attempt 1,2,3)” problem.

Also often I try to “configure” the game, and it’s reset the runner to “Linux”. It happens randomly but often enough that I think it’s annoying.

I’m going to try and fiddle with some of the ideas at https://appdb.winehq.org/objectManager.php?sClass=version&iId=34726 and see if I can log in.

E1: I have a theory of why some information would get reset. Does Lutris look for game executables in /usr/bin first? I had an executable there which perhaps Lutris extracted information from?

E2: Fixed by switching to wine staging 2.2 i386. But game consistently freezes after a few seconds. Tried fullscreen and windowed mode. Always freezes after about 15 seconds. Going to try and get the beta client to work and maybe see what I find in the command line.

I’ve tried running LoL a few days ago (mostly to fix the installer, I don’t play LoL) and it was not a complete success.

Btw, you’re describing one of the issues I ran into while doing that which is desktop shortcuts overriding previously installed games (I also had the LoL launcher in /usr/bin). I temporarily solved it by removing the launcher but this needs fixing.