christianhaitian / arkos

Another rockchip Operating System
MIT License
1.37k stars 81 forks source link

Scraping "only missing medias" scrapes EVERYTHING (instead of 'only missing') #1080

Closed Dochartaigh closed 1 month ago

Dochartaigh commented 1 month ago

Describe the Issue (If applicable)

Scraping with the "only missing medias" option scrapes the ENTIRE game directory, and not just games with missing media.

How can the issue be reproduced? (If applicable)

Start > Scraper > Scrape Now (have my ScrenScraper.fr user/pass setup already) > Filter: "only missing medias" > Select your system(s) --only 1x in my case > Start... and you'll see it's re-scraping EVERYTHING all over again and not just the SINGLE game I added.

What device are you using?

Powkiddy RGB30 V2 (assume it's v2 since I have the newer buttons)

What version of ArkOS are you on?

Newest "RGB30 | (Updated 10/16/2023) MD5:0C65C5C7D7CFEE353AE9FB30B42B2159"

Anything else you'd like to include that may help to review this issue or feature request?

Only making this ticket because this can literally add DAYS of extra scraping... Last night I added 1 single game to my NES rom folder... should have taken ~30 seconds to download the box art and video for that ONE single game... but instead took me ~8 HOURS to scrape my entire NES folder last night (~8K games... even have 7x threads on ScreenScraper.fr...).

Also to note: after this happened, I imaged a new version of ArkOS onto another SD card and this same issue persists. The ONLY things I did on the new setup was turn on WiFi, then tried this. I did not update the new install, but the old one DID have everything updated (which took around 2 hours, so assume it had newest everything).

christianhaitian commented 1 month ago

I can't replicate this issue on my end. As an example, I scraped my list of 50 NES roms that had not been previously scraped. Then added a couple of additional roms and scraped them again and it only scraped the 2 additional roms I added. Are you using scraped roms and gamelist.xml from another setup that is possibly not recognized by scraper in the ES used by ArkOS? The scraper used here is expecting the gamelist.xml to have entries similar to the following:

<?xml version="1.0"?>
<gameList>
    <game>
        <path>./Contra I.zip</path>
        <name>Contra</name>
        <desc>In the year 2631, a small meteorite has fallen into the Galuga archipelago, located 20km northeast off the coast of New Zealand. Two years later, a terrorist group known as Red Falcon has seized the island in preparation for an alien invasion. The earth's marines sent two members of their elite Contra unit, Bill Rizer and Lance Bean, to neutralize the terrorists.

As either, Bill (player 1) or Lance (player 2), the player must get to the end of each stage, shooting everything in sight, while avoiding enemy fire themselves. The player can upgrade their standard-issue rifle into one of four different weapons, including the powerful spread shot.</desc>
        <image>./images/Contra I-image.png</image>
        <marquee>./images/Contra I-marquee.png</marquee>
        <thumbnail>./images/Contra I-thumb.png</thumbnail>
        <rating>0.9</rating>
        <releasedate>19880202T000000</releasedate>
        <developer>Konami</developer>
        <publisher>Konami</publisher>
        <genre>Shooter / Run and Gun</genre>
        <players>2</players>
        <playcount>1</playcount>
        <lastplayed>20240214T145245</lastplayed>
    </game>
    <game>
        <path>./Contra II - Super C.zip</path>
        <name>Contra</name>
        <desc>In the year 2631, a small meteorite has fallen into the Galuga archipelago, located 20km northeast off the coast of New Zealand. Two years later, a terrorist group known as Red Falcon has seized the island in preparation for an alien invasion. The earth's marines sent two members of their elite Contra unit, Bill Rizer and Lance Bean, to neutralize the terrorists.

As either, Bill (player 1) or Lance (player 2), the player must get to the end of each stage, shooting everything in sight, while avoiding enemy fire themselves. The player can upgrade their standard-issue rifle into one of four different weapons, including the powerful spread shot.</desc>
        <image>./images/Contra II - Super C-image.png</image>
        <marquee>./images/Contra II - Super C-marquee.png</marquee>
        <thumbnail>./images/Contra II - Super C-thumb.png</thumbnail>
        <rating>0.9</rating>
        <releasedate>19880202T000000</releasedate>
        <developer>Konami</developer>
        <publisher>Konami</publisher>
        <genre>Shooter / Run and Gun</genre>
        <players>2</players>
    </game>
    <game>
        <path>./Super Mario Bros III.zip</path>
        <name>Super Mario Bros. 3</name>
        <desc>Bowser is back, and along with the Bowser kids, he's out to spoil Mario's day once again. 

This time, along with nabbing the Princess, the Bowser crew have also taken the magic wands from the Kings of each land and turned them into creatures.
It's up to Mario and Luigi to get back the magic wands, defeat Bowser, and save the Princess all before the day is done.

Old and new power-ups abound in each level for the Mario Brothers, including the return of the Super Mushroom and Fire Flower, plus the new power-ups including the frog suit, the warp flute, and the most important of all, the leaf, which allows the player to fly and attack enemies with your tail.</desc>
        <image>./images/Super Mario Bros III-image.png</image>
        <marquee>./images/Super Mario Bros III-marquee.png</marquee>
        <thumbnail>./images/Super Mario Bros III-thumb.png</thumbnail>
        <rating>0.95</rating>
        <releasedate>19900212T000000</releasedate>
        <developer>Nintendo</developer>
        <publisher>Nintendo</publisher>
        <genre>Platform</genre>
        <players>1-2</players>
        <playcount>5</playcount>
        <lastplayed>20240214T152003</lastplayed>
    </game>
</gameList>

If your gamelist is not similar to this, the scraper may assume that your games have missing medias and rescrape them in order to follow this standard.

christianhaitian commented 1 month ago

Also, make sure you do an OTA update to the latest version of ArkOS which 04/24/2024 as of the date and time of this comment.

Dochartaigh commented 1 month ago

Also, make sure you do an OTA update to the latest version of ArkOS which 04/24/2024 as of the date and time of this comment.

Thanks again for replying! (and just want to tell you how refreshing it is to have a developer so active in troubleshooting - you don't know how amazing that is from the end-users viewpoint! AND super-rare too!!! THANK YOU THANK YOU).

Back to the question: I have to admit I'm not 100% sure... but these might (probably?) were previously scraped with Rocknix. I was told you can 'seamlessly' swap the system/smaller 16GB card from OS to OS and leave the larger 2nd game SD card in the device (which keeps gamelists and all the scraped media) and it'll 'just work' between any OS on these dual-SD-card devices, and you do NOT have to re-scrape or regenerate rom lists or anything... but sounds like that may not be the case?

I DID notice "gamelist.xml.old" being in each individual rom folder when I switched from Rocknix to ArkOS (I'm a convert to yours - honestly just seems better... and I can do SIMPLE things like change the es_systems.cfg on yours... which is 1000% locked-down on Rocknix and impossible to change, for example) ... and it might have been Arkos replacing/archiving the gamelists into that .old format, but I'm not positive. The old vs. the new gamelist files are the same exact size down to the byte fyi... so think they're still the same exact files.

Ayway, I pulled up my NES gamelist, and besides NOT having all the descriptors yours has (developer, game description, number of player, etc.), mine DO seem to be in the same exact format as yours otherwise with: "Path, Name, MD5", with "game /game" separating them per usual:

Screenshot 2024-05-24 at 12 24 52 PM

I also ran a little test. Since when I tried to scrape that ONE single rom last time, and it re-scraped the entire 7,000+ game library, I thought it's safe to assume that ALL the scraped media and gamelist are now in the proper/official ArkOS gamelists format (if that is indeed the issue here), right? So to test this I added another SINGLE game to NES, rebooted emulationstation, then re-scraped with "only missing medias" – and it again started scraping the ENTIRE system, and not just that one game!

I'm now going to re-flash my 3rd image of ArkOS onto another fresh 16GB card. After it boots up for the very first time I'll run the 'Options > Update' as the VERY first thing (that's the "OTA update" you mentioned, right? I don't know that "OTA" stands for). Before inserting my SanDisk 256gb 2nd game SD card, I'm going to take a smaller rom folder and delete all the media/art/gamelist files so it's fresh/untouched. I'll then scrape regular (EVERYTHING), reboot, then add a single game, and re-scraped with "only missing medias" to see if it only does that ONE game, or mistakenly does everything (like it's done the last several times). Does that sound like a good test? I can film it if you want... have a feeling it's going to do the same thing as the last 2x ArkOS images I flashed (one was fully updated, the last wasn't). But I'm sorry to say, this being my 3rd time imaging the same ArkOS I have little hope it'll magically start working a different way... (sorry, don't want to be negative... just factual/logical).

christianhaitian commented 1 month ago

In theory, ROCKNIX or JELOS sd card will work without issue in ArkOS or vice versa, however, there are some slight differences with the version of Emulationstation (ES) both use and you may be running into one of the slight differences here. Here's what I suggest, just start with a small library first of like 20 or less games for NES. scrape that. Add a few more games, then scrape that again and see if it tries to do the whole library or just the few you added. I suspect when it comes to media, how the ES views available scraped media between the 2 different versions we use may be the issue you're running into.

christianhaitian commented 1 month ago

Oh and OTA update is short for Over The Air update.

christianhaitian commented 1 month ago

Any update on this?

Dochartaigh commented 1 month ago

Any update on this?

Sorry, was down the shore for the holiday weekend. And YES - you are right, it seems to be something in the Rocknix-created gamelist.xml (I think) which is screwing it up. I added a whole other system I had never scraped, then scraped it, then added 1x single game and re-scraped and it DID scrape JUST that game. I also did a fresh SD card flash of your ArkOS first as well... but don't think that had anything to do with it - think it was that pesky Rocknix gamelist.xml (despite the code looking nearly exact to each other at first glance... so don't know what exactly in that file is messing it up). Also to note, that even if ArkOS rescrapes EVERY game which you would think would fix this issue, it STILL doesn't work... so another mystery there too ;)