mirror of
https://github.com/rommapp/romm.git
synced 2026-12-03 18:43:23 +01:00
The guard exists to refuse a second pass over the library: a client that lost the progress socket cannot tell one is running, and pressing scan again queued another. A scan of named roms is not that. It resolves its work from the database, skips the filesystem walk and is done in seconds, so refusing it only loses a click the user has to remember to repeat. The refresh-metadata dialog makes this worse than one lost click. It fans a selection that spans platforms into one request per platform, so the first was accepted and the rest refused: selecting roms from three platforms refreshed one platform's worth and raised two errors. Scans of named roms are now always accepted, and enqueued at the front so they go ahead of any library scan already waiting rather than behind it. Only library scans block a library scan. `at_front` cannot help while a scan is running, though: the worker is inside that job and does not look at the queue again until it returns. Running a rom refresh alongside a library scan needs a second lane, and a way for a client to tell whose progress events are whose. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>