Skip cover/metadata scraping for NoPayStation themes and DLC

This commit is contained in:
2026-09-07 23:53:55 -04:00
parent c94bcdc993
commit 2fed95da05
4 changed files with 49 additions and 11 deletions
+11
View File
@@ -30,6 +30,15 @@ _PLATFORMS = {
"ps1": {"libretro_repo": "Sony_-_PlayStation", "igdb_id": 7, "ss_id": "57"},
}
# Content types that have no meaningful cover/metadata (IGDB/etc. lookups
# return unrelated games, so scraping is disabled for them).
NON_COVER_SYSTEMS = {"theme", "dlc"}
def is_scrapable(system):
"""Whether cover/metadata scraping makes sense for this item type."""
return (system or "games") not in NON_COVER_SYSTEMS
def _platform(system):
"""Platform parameters (libretro repo, IGDB id, ScreenScraper id)."""
@@ -1142,6 +1151,8 @@ def fetch_cover(name, release_id, system, timeout=10, quick=False):
``quick`` limits the game fallback to libretro only (index-driven and fast),
for bulk store loading; details views use the full IGDB/ScreenScraper path.
"""
if not is_scrapable(system):
return None
dest = cover_path(release_id, system)
if dest.exists():
if file_is_image(dest):