tralph3 / Steam-Metadata-Editor

An easy to use GUI that edits the metadata of your Steam Apps
GNU General Public License v3.0
161 stars 18 forks source link

Problematic performance #42

Open romatthe opened 8 months ago

romatthe commented 8 months ago

Hi there, thanks for writing this little program, I used it to clean up my library on Linux, so I really appreciate you putting this together!

Unfortunately, I am running into issues with performance. As suggested, I actually launch the application with the --silent switch before opening Steam as suggested (by setting Exec=sh -c 'steam-metadata-editor --silent; steam %U' in the desktop file. This actually works well, but actually running the program has become very slow lately (making Steam boot time very slow as well).

$ time steam-metadata-editor --silent

________________________________________________________
Executed in   10.31 secs    fish           external
   usr time   10.03 secs  208.00 micros   10.03 secs
   sys time    0.16 secs   52.00 micros    0.16 secs

I mainly edit the display name of games as well as how they're sorted. But because SME dumps all the original data into the json file before editing, my modifications.json has grown quite gargantuan in size:

$ ls -lah ~/.local/share/Steam-Metadata-Editor/config/modifications.json
.rw-r--r-- romatthe users 33 MB Thu Nov  2 22:03:07 2023 modifications.json

Funny detail, it has actually become larger in size than my actual appinfo.vdf!

$ ls -lah ~/.local/share/Steam/appcache/appinfo.vdf
.rwxr-xr-x romatthe users 32 MB Thu Nov  2 22:03:09 2023 appinfo.vdf

I should point out however that I do have a pretty big Steam library (2600+ games, please send help), and I am pretty OCD when it comes to keeping everything quite clean, so I assume the issue will be less exaggerated for most users.

Either way, I felt like I needed to post this here just to let you know, but please don't worry about it TOO much. My solution will probably just end up my writing my own tool instead.

(Speaking of which, is the appcache.vdf or the binary vdf format documented anywhere aside from people's ad-hoc implementations?)

tralph3 commented 8 months ago

Well, that's the biggest appinfo I've seen yet, and you must have modified quite a bit of games to grow the json that large.

I can try to take a look at the performance. If you don't mind, having your modifications file may prove useful to see what is making it so slow.

The format is documented here: https://github.com/SteamDatabase/SteamAppInfo

romatthe commented 8 months ago

Yeah, it's like I said, I don't expect the average user to run into this issue since the combo of a big library and me being overtly obsessive about how I sort and name the games is likely an extreme outlier.

Here's my (gzipped) modifications.json: modifications.json.gz

Again, I felt it was worth mentioning my issue, but definitely don't waste too much time on this since I understand most people using the app will probably not have this issue.

(And thanks for the documentation link!)