You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When I load the Dreamcast platform (in which I have some multi disc games), I get "Couldn't fetch roms for platform ID 15: AxiosError: Request failed with status code 500" in the UI. The 500 is on /api/roms?platform_id=15&search_term=&order_by=name&order_dir=asc. Checking the log, I see a pydantic ValidationErrror:
pydantic_core._pydantic_core.ValidationError: 5 validation errors for SimpleRomSchema
files.0
Input should be a valid dictionary [type=dict_type, input_value='D2 (USA).m3u', input_type=str]
For further information visit https://errors.pydantic.dev/2.8/v/dict_type
files.1
Input should be a valid dictionary [type=dict_type, input_value='D2 (USA) (Disc 4).chd', input_type=str]
For further information visit https://errors.pydantic.dev/2.8/v/dict_type
files.2
Input should be a valid dictionary [type=dict_type, input_value='D2 (USA) (Disc 3).chd', input_type=str]
For further information visit https://errors.pydantic.dev/2.8/v/dict_type
files.3
Input should be a valid dictionary [type=dict_type, input_value='D2 (USA) (Disc 2).chd', input_type=str]
For further information visit https://errors.pydantic.dev/2.8/v/dict_type
files.4
Input should be a valid dictionary [type=dict_type, input_value='D2 (USA) (Disc 1).chd', input_type=str]
For further information visit https://errors.pydantic.dev/2.8/v/dict_type
To Reproduce
Add a multi disc game to a platform in v3.4.0, like the following:
Scan the platform.
Update to v3.5.0 alpha 1.
Open that platform in the Romm frontend.
Expected behavior
The platform's game list should load without error.
Screenshots
Desktop (please complete the following information):
Some detail on the cause: the files column on the roms table used to be a list[str], but now it's a list[RomFile]. However, in my database, ~47 rom records still have strings instead of objects:
select json_type(json_extract(files, "$[0]")) as type, count(*)
from roms
group by type
type
count(*)
null
1608
OBJECT
565
STRING
47
I'm not sure why 47 records failed to convert to object, or how to force them to convert (short of manually updating the db records)
Thanks for investigating this! I was about to add that triggering any scan will fix the files array, and that the latest alpha release should trigger a scan on startup (through a migration). In any case we'll add a note in the release notes to manually run a scan if it doesn't trigger automatically on upgrade.
BTW if you're interested in testing future pre-releases, there's a closed Alpha Testers group on our Discord. We'd love to have you join it! https://discord.gg/PDGPX6tZ
RomM version
1.5.0 alpha 1
Describe the bug
When I load the Dreamcast platform (in which I have some multi disc games), I get "Couldn't fetch roms for platform ID 15: AxiosError: Request failed with status code 500" in the UI. The 500 is on
/api/roms?platform_id=15&search_term=&order_by=name&order_dir=asc
. Checking the log, I see a pydantic ValidationErrror:To Reproduce
Add a multi disc game to a platform in v3.4.0, like the following:
Scan the platform.
Update to v3.5.0 alpha 1.
Open that platform in the Romm frontend.
Expected behavior
The platform's game list should load without error.
Screenshots
Desktop (please complete the following information):
Additional Context
_romm_logs (1).txt
The text was updated successfully, but these errors were encountered: