From d41933cdcf76a8c366a992e312473f230a3efebe Mon Sep 17 00:00:00 2001 From: Abdessamad Derraz <3028866+Abdess@users.noreply.github.com> Date: Sat, 17 Oct 2026 18:16:44 +0200 Subject: [PATCH] fix: let agnostic profiles claim no slot A filename-agnostic profile ships its scan candidates, never its named entries, and the gap report skips it whole. Its entries no longer arbitrate a destination: RetroArch keeps the GameIndex.yaml it declares instead of the ARMSX2 copy. --- scripts/slots.py | 4 ++++ tests/test_slots.py | 14 ++++++++++++++ 2 files changed, 18 insertions(+) diff --git a/scripts/slots.py b/scripts/slots.py index 244bb259..eed245a2 100644 --- a/scripts/slots.py +++ b/scripts/slots.py @@ -175,6 +175,10 @@ def profile_claims( for emu_name, profile in sorted(profiles.items()): if profile.get("type") in ("launcher", "alias"): continue + # The gap report skips a filename-agnostic profile whole: the builder + # carries its scan candidates, never its named entries. + if profile.get("bios_mode") == "agnostic": + continue is_standalone = runs_standalone(emu_name, profile, standalone_cores) claims.extend( _archive_claims( diff --git a/tests/test_slots.py b/tests/test_slots.py index 24ee635d..0a5d9266 100644 --- a/tests/test_slots.py +++ b/tests/test_slots.py @@ -310,6 +310,20 @@ class TestConflicts(unittest.TestCase): ) self.assertEqual(slots.profile_claims(profile, REGIONS_DB), []) + def test_a_filename_agnostic_profile_claims_nothing(self): + """The gap report skips a `bios_mode: agnostic` profile whole: the + builder carries its scan candidates, never its named entries. + ARMSX2's GameIndex.yaml replaced the one RetroArch declares.""" + profile = self._profile("GC/JAP/IPL.bin") + self.assertTrue( + slots.find_conflicts(self._config("m" * 32), profile, REGIONS_DB) + ) + profile["dolphin"]["bios_mode"] = "agnostic" + self.assertEqual(slots.profile_claims(profile, REGIONS_DB), []) + self.assertEqual( + slots.find_conflicts(self._config("m" * 32), profile, REGIONS_DB), [] + ) + def test_base_destination_prefixes_both_sides(self): conflicts = slots.find_conflicts( self._config("m" * 32),