BlueManCZ / SIF

:video_game: Steam Icons Fixer - Fix runtime icons of Steam games on Linux.
Apache License 2.0
53 stars 4 forks source link

Unable to run without error #18

Closed zt64 closed 3 years ago

zt64 commented 3 years ago

I am on Ubuntu 20.04, with Python 3.8.5. I've made sure to install everything but when I run the python file I just get an error. At first, it will work fine and ask me to terminate steam but then that's when it messes up.

Creating .desktop files in /home/litleck/.local/share/applications/steam-icons-fixed

Traceback (most recent call last):
  File "./sif.py", line 492, in <module>
    fix_launch_option(game, game_wm_name, game_wm_name_alt)
  File "./sif.py", line 157, in fix_launch_option
    apps = loaded['UserLocalConfigStore']['Software']['Valve']['Steam']['Apps']
KeyError: 'Apps'

I have no clue what this means but I was hoping maybe I could get help here.

BlueManCZ commented 3 years ago

Hello @Litleck! Never seen this error before. Can you please run the script with --verbose flag and post the output here?

zt64 commented 3 years ago

Hello @Litleck! Never seen this error before. Can you please run the script with --verbose flag and post the output here?

Here you go


[ok] Found Steam installation directory:
   - /home/litleck/.steam/steam

[ok] Found Steam configuration file:
   - /home/litleck/.steam/steam/config/config.vdf

[ok] Found Steam library folders:
   - /home/litleck/.steam/steam/steamapps

[ok] Found Steam localconfig.vdf file:
   - /home/litleck/.steam/steam/userdata/159469981/config/localconfig.vdf

[ok] Found wm-class-database file:
   - /home/litleck/Downloads/SIF/wm-class-database.json

[ok] Found target directory:
   - /home/litleck/.local/share/applications/steam-icons-fixed

Creating .desktop files in /home/litleck/.local/share/applications/steam-icons-fixed

Traceback (most recent call last):
  File "./sif.py", line 492, in <module>
    fix_launch_option(game, game_wm_name, game_wm_name_alt)
  File "./sif.py", line 157, in fix_launch_option
    apps = loaded['UserLocalConfigStore']['Software']['Valve']['Steam']['Apps']
KeyError: 'Apps'
BlueManCZ commented 3 years ago

This is strange. Can you post content of your /home/litleck/.steam/steam/userdata/159469981/config/localconfig.vdf file? For example on https://pastebin.com/. It is the file that causes this problem. Inside should be JSON structure looking like this:

"UserLocalConfigStore"
{
    "Software"
    {
        "Valve"
        {
            "Steam"
            {
                "Apps"
                {

And for some reason, your "Apps" key is missing.

BlueManCZ commented 3 years ago

By the way, when script asks you to terminate Steam and you answer No, it should run fine. Am I right?

zt64 commented 3 years ago

This is strange. Can you post content of your /home/litleck/.steam/steam/userdata/159469981/config/localconfig.vdf file? For example on pastebin.com. It is the file that causes this problem. Inside should be JSON structure looking like this:

"UserLocalConfigStore"
{
  "Software"
  {
      "Valve"
      {
          "Steam"
          {
              "Apps"
              {

And for some reason, your "Apps" key is missing.

https://pastebin.com/vjcqhHCB

By the way, when script asks you to terminate Steam and you answer No, it should run fine. Am I right?

Yes, it says that Some games couldn't be fixed due to running Steam

BlueManCZ commented 3 years ago

Pastebin says it's no longer available. Could you try it again?

BlueManCZ commented 3 years ago

Just to make sure, this command find /home/litleck/.steam/steam/userdata/ | grep localconfig.vdf returns only one file, right?

zt64 commented 3 years ago

My bad, here's the Pastebin again https://pastebin.com/DGQcN6U2 And that command does return only one file. /home/litleck/.steam/steam/userdata/159469981/config/localconfig.vdf

BlueManCZ commented 3 years ago

It still doesn't work. Does it work for you in an anonymous window? You can try https://dpaste.com/

zt64 commented 3 years ago

It still doesn't work. Does it work for you in an anonymous window? You can try dpaste.com

https://dpaste.com/A8VVSVTCN Hopefully this one works

zt64 commented 3 years ago

It seems like it has some limit to the content size

BlueManCZ commented 3 years ago

Is that file cut on line 115 in your system too?

zt64 commented 3 years ago

Yes

BlueManCZ commented 3 years ago

It is not dpaste related?

zt64 commented 3 years ago

In the preview on dpaste it shows all the content in there but on the actual link its cut off at that line.

https://hastebin.com/ehomeqefow.pl This should work

BlueManCZ commented 3 years ago

Great! I see a problem. Your file uses "apps" as a key instead of "Apps" for some reason. I will try to fix this in the script and let you know.

BlueManCZ commented 3 years ago

Does it work for you now, when you update with git pull?

zt64 commented 3 years ago

Does it work for you now, when you update with git pull?

That seems to have fixed it. Thank you.