Repository navigation
Conversation
A zipped ROM unpacked on download lost its archive, and grout only looked for the exact file name RomM reports, so the game never showed as downloaded (rommapp#233). Multi-file games were unpacked into a folder while grout looked for a playlist at the root, which only muOS creates. - Decode RomM's archive_members (name only) and treat an archive as present when every file listed inside it is on the card. - When the server lists nothing (RomM 4.x, hashing off, old scans), fall back to a file or folder sharing the archive's name, ignoring saves, states, patches, art and text files. Directory listings are cached per ROM directory until its modification time changes. - Accept a multi-file game's extraction folder, named per firmware through a new ExtractedDirName hook (_<name> on muOS). - LocalPath returns the file to launch for an unpacked game (playlist first, then the first file), so the metadata refresh points at it. - Move IsArchive to the archive package so cfw can use it. - Add ADR 0001 describing the options and the decision. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes rommapp#233.
Problem
Grout keeps no record of what it downloads. To mark a game as downloaded, it checks that the exact file name RomM reports exists on the card. Unpacking a download changes that name:
Game.zipis deleted after unpacking, so grout looks for a file that no longer exists.<name>/, while grout looks for<name>.m3uat the root. Only muOS moves the playlist up, and only when the archive has one; on muOS the folder is_<name>/.Change
Option D + A from the ADR (
docs/contributing/adr/0001-detect-extracted-roms.md):archive_members(name only, to save memory on 128 MB devices). An archive counts as present when every file listed inside it is on the card. The field has been inRomFileSchemasince RomM 5.0.0; I checked it in a real API response from RomM 5.3.1.ExtractedDirName, gives its name (_<name>on muOS).LocalPathreturns the file to launch for an unpacked game: the.m3uif there is one, otherwise the first file. The metadata refresh then points at the right file.IsArchivemoves fromdownloadtoarchivesocfwcan use it without an import cycle.Tests
cfw: listed archive members, members taking precedence over the name, members outside the ROM directory, fallback by name and its exclusions, extraction folders (including muOS),LocalPathfor unpacked games, the directory listing cache.catalog: end-to-end on a simulated muOS card, including the real RomM payload (a zip holding a folder of CHDs and an.m3u).romm: decodingarchive_members, includingnull.go vetandgo test ./...pass.Not verified yet
archive_membersfor games it fetches again, and the incremental sync only fetches games changed on the RomM side. Fallback A covers the rest until a full library refresh.🤖 Generated with Claude Code