mmatyas / pegasus-frontend

A cross platform, customizable graphical frontend for launching emulators and managing your game collection.
http://pegasus-frontend.org
Other
1.19k stars 106 forks source link

Crash if metadata lists game with no ROM #795

Closed valsou closed 3 years ago

valsou commented 3 years ago

The issue

Pegasus crash if it is showing a collection with a game listed in the metadata.txt that doesn't exist (no rom file).

System info

Tested on Android phones (Huawei P30, others have issue with Retroid Pocket 2). Should be the same on other OS, but not tested.

Pegasus version

Since Weekly build #5, especially this commit : https://github.com/mmatyas/pegasus-frontend/commit/f1f4ecddc22ac08e0ee39088d886c605f79e23d1

Pegasus log

2021-01-22T19:40:44 [w] Metafiles: `\\192.168.1.2\roms\sony_psp\metadata.txt`, line 1560: Game file `\\192.168.1.2\roms\sony_psp\Ys - The Ark of Napishtim (Europe) (En,Fr,De,Es,It) (v1.03).cso` doesn't seem to exist
2021-01-22T19:40:44 [w] Metafiles: `\\192.168.1.2\roms\sony_psp\metadata.txt`, line 1578: Game file `\\192.168.1.2\roms\sony_psp\Ys - The Oath In Felghana (USA).cso` doesn't seem to exist
2021-01-22T19:40:44 [w] Metafiles: `\\192.168.1.2\roms\sony_psp\metadata.txt`, line 1597: Game file `\\192.168.1.2\roms\sony_psp\Ys - Seven (USA).cso` doesn't seem to exist
2021-01-22T19:40:44 [i] Metafiles: Finished searching in 485ms
2021-01-22T19:40:44 [i] Media: Finished searching in 540ms
2021-01-22T19:40:44 [i] Favorites: Finished searching in 1ms
2021-01-22T19:40:44 [i] Playtime: Finished searching in 0ms
2021-01-22T19:40:44 [i] Game list post-processing took 4ms
2021-01-22T19:40:44 [i] 83 games found
2021-01-22T19:40:50 [e] QQmlEngine: Illegal attempt to connect to model::Game(0x757fdd8) that is in a different thread than the QML engine QQmlApplicationEngine(0x4500de0.
djfumberger commented 3 years ago

Confirming I'm also seeing the same issue under Android 6 / Retroid Pocket 2.

Have observed on the default Pegasus Grid Theme, though interestingly wasn't able to replicate on the Famicom Beach Theme, so wonder if there's a connection to cover art here.

Also wasn't able to replicate on macos when pointing Pegasus at the same SD card & metadata file that was causing issues under Android.

trvrplk commented 3 years ago

I'm having a similar issue, but it occurs when the metadata.txt file has two listings for the same ROM

valsou commented 3 years ago

It's fixed for me. :+1:

Maybe others can give their feedback, before closing the issue.

Thanks Matyas.

mmatyas commented 3 years ago

Yes, this should be fixed now in the latest version.

@trvrplk I couldn't reproduce this with the latest version, but if you still do, feel free to open a new issue with an example metadata file!

trvrplk commented 3 years ago

Yep, latest version fixed it!

jasonfonghk commented 3 years ago

Hello @mmatyas , I still have this issue on the latest version. Could you check it? thanks.

My metadata content:

collection: CPS extensions: 7z, zip launch: "\Pegasus-wkzlm\RetroArch\retroarch.exe" -L "\Pegasus-wkzlm\RetroArch\cores\fbalpha2012_libretro.dll" "{file.path}" game: 1941 file: 1941.zip developer: 1941 description: 1941

When I put missing entry on the meta data, It will be crashed.

I pasted the lastrun.log for reference.

2021-03-21T22:17:25 [i] Pegasus alpha14-110-g89e3693b (2021-02-04) 2021-03-21T22:17:25 [i] Running on Windows 10 Version 2004 (x86_64, windows) 2021-03-21T22:17:25 [i] Qt version 5.15.2 2021-03-21T22:17:25 [i] Program settings loaded (D:/Pegasus-wkzlm2/aa/config/settings.txt) 2021-03-21T22:17:25 [i] Found locale ar 2021-03-21T22:17:25 [i] Found locale bs 2021-03-21T22:17:25 [i] Found locale de 2021-03-21T22:17:25 [i] Found locale en-GB 2021-03-21T22:17:25 [i] Found locale en 2021-03-21T22:17:25 [i] Found locale es 2021-03-21T22:17:25 [i] Found locale fr 2021-03-21T22:17:25 [i] Found locale hu 2021-03-21T22:17:25 [i] Found locale ko 2021-03-21T22:17:25 [i] Found locale nl 2021-03-21T22:17:25 [i] Found locale pt-BR 2021-03-21T22:17:25 [i] Found locale ru 2021-03-21T22:17:25 [i] Found locale zh-TW 2021-03-21T22:17:25 [i] Found locale zh 2021-03-21T22:17:25 [i] Locale set to en 2021-03-21T22:17:25 [i] Found theme Pegasus Grid at :/themes/pegasus-theme-grid/ 2021-03-21T22:17:25 [i] Theme set to Pegasus Grid (:/themes/pegasus-theme-grid/) 2021-03-21T22:17:25 [i] SDL version 2.0.10 2021-03-21T22:17:26 [i] Gamepad: Connected device 0x0 (ShanWan PS3/PC Wired GamePad) 2021-03-21T22:17:26 [i] Metafiles: Found D:\Pegasus-wkzlm2\Roms-v2.0\CPS1\metadata.pegasus.txt 2021-03-21T22:17:26 [w] Metafiles: D:\Pegasus-wkzlm2\Roms-v2.0\CPS1\metadata.pegasus.txt, line 6: Game file D:\Pegasus-wkzlm2\Roms-v2.0\CPS1\1941.zip doesn't seem to exist 2021-03-21T22:17:26 [i] Metafiles: Finished searching in 1ms 2021-03-21T22:17:26 [i] Media: Finished searching in 0ms 2021-03-21T22:17:26 [i] Favorites: Finished searching in 0ms 2021-03-21T22:17:26 [i] Playtime: Finished searching in 0ms 2021-03-21T22:17:26 [i] Steam: No installation found 2021-03-21T22:17:26 [i] Steam: Finished searching in 0ms 2021-03-21T22:17:26 [i] GOG: 0 games found 2021-03-21T22:17:26 [i] GOG: Finished searching in 0ms 2021-03-21T22:17:26 [i] EmulationStation: No installation found 2021-03-21T22:17:26 [i] EmulationStation: Finished searching in 0ms 2021-03-21T22:17:26 [i] Skraper Assets: 0 assets found 2021-03-21T22:17:26 [i] Skraper Assets: Finished searching in 1ms 2021-03-21T22:17:26 [i] LaunchBox: No installation found 2021-03-21T22:17:26 [i] LaunchBox: Finished searching in 0ms 2021-03-21T22:17:26 [i] Logiqx: Finished searching in 0ms 2021-03-21T22:17:26 [w] The collection 'GOG' has no valid games, ignored 2021-03-21T22:17:26 [i] Game list post-processing took 0ms 2021-03-21T22:17:27 [i] 1 games found 2021-03-21T22:17:27 [e] QQmlEngine: Illegal attempt to connect to model::Game(0xc136040) that is in a different thread than the QML engine QQmlApplicationEngine(0x2d23ef0.

Thanks.

mmatyas commented 3 years ago

Hi, you're running the older, stable version, the latest one is alpha14-130-gf59598fa.

jasonfonghk commented 3 years ago

Hi, you're running the older, stable version, the latest one is alpha14-130-gf59598fa.

Thanks for your quick replay, I confirmed the Latest version "alpha14-130-gf59598fa (2021-03-21)" is solved this issue.

Btw, the official site still showing: Stable release: alpha14-110-g89e3693b (2021-02-07) I think the "stable release" on is not really "stable", because the stable release has this crash issue.

mmatyas commented 3 years ago

Great!

I think the "stable release" on is not really "stable", because the stable release has this crash issue.

Yes, in this case stable refers more about how well the features are tested, but, like with this issue, there might be still some leftover bugs. On the other hand the last stable release has been indeed quite a while ago, so might be about time to have a new one.