verifydump
verifydump copied to clipboard
verifydump chokes on filenames containing brackets []
As stated, a filename such as:
XI [sai] (Japan) (Demo 2).chd
Will cause the following error in PowerShell 7, Windows 11:
W:\PlayStation (CHD)>verifydump.exe --extra-cue-source "R:_Emu_ROM Managers\DATs\Redump (Other)\Cuesheets" "R:_emu_ROM Managers\DATs\1G1R\Redump\Sony - PlayStation (2022-07-01 03-24-24) (Retool 2022-07-06 12-33-55) (6,196).dat" ".\XI [sai] (Japan) (Demo 2).chd"
Datfile loaded successfully with 6196 games
Traceback (most recent call last):
File "exeentry.py", line 5, in
Simply renaming the file, removing the brackets causes it to work correctly, though it does then complain about the filename not matching the DAT.
That's an interesting one. Thanks very much for the report!
Happy to help in any way I can, verifydump has saved me countless hours of work!
The problem is in convert.py on line 56--the pathlib glob treats the brackets in the filename as part of the pattern to match.
I changed the pattern to "*(Track *).bin" and tested it against "Holiday Special (Japan).chd" which has only one .bin and "XI [sai] (Japan) (Demo 2).chd" and both verified successfully (this is with verbose on):
Loading Datfile "Sony - PlayStation - Datfile (10660) (2022-07-20 18-03-14).dat" from "Sony - PlayStation - Datfile (10660) (2022-07-20 18-03-14).zip" Datfile loaded successfully with 10660 games Verifying dump file "S:\Roms\ps\Holiday Special (Japan).chd" Converting "Holiday Special (Japan).chd" to .bin/.cue format Splitting "Holiday Special (Japan).cue" to use separate tracks if necessary Renaming "Holiday Special (Japan) (Track 1).bin" to "Holiday Special (Japan).bin" because there is only one .bin file in the dump Dump file "Holiday Special (Japan).bin" found in Dat and verified Dump file "Holiday Special (Japan).cue" found in Dat and verified Dump verified correct and complete: "Holiday Special (Japan)" Verifying dump file "S:\Roms\ps\XI [sai] (Japan) (Demo 2).chd" Converting "XI [sai] (Japan) (Demo 2).chd" to .bin/.cue format Splitting "XI [sai] (Japan) (Demo 2).cue" to use separate tracks if necessary Dump file "XI [sai] (Japan) (Demo 2) (Track 01).bin" found in Dat and verified Dump file "XI [sai] (Japan) (Demo 2) (Track 02).bin" found in Dat and verified Dump file "XI [sai] (Japan) (Demo 2) (Track 03).bin" found in Dat and verified Dump file "XI [sai] (Japan) (Demo 2) (Track 04).bin" found in Dat and verified Dump file "XI [sai] (Japan) (Demo 2) (Track 05).bin" found in Dat and verified Dump file "XI [sai] (Japan) (Demo 2) (Track 06).bin" found in Dat and verified Dump file "XI [sai] (Japan) (Demo 2) (Track 07).bin" found in Dat and verified Dump file "XI [sai] (Japan) (Demo 2) (Track 08).bin" found in Dat and verified Dump file "XI [sai] (Japan) (Demo 2) (Track 09).bin" found in Dat and verified Dump file "XI [sai] (Japan) (Demo 2) (Track 10).bin" found in Dat and verified Dump file "XI [sai] (Japan) (Demo 2) (Track 11).bin" found in Dat and verified Dump file "XI [sai] (Japan) (Demo 2) (Track 12).bin" found in Dat and verified Dump file "XI [sai] (Japan) (Demo 2).cue" found in Dat and verified Dump verified correct and complete: "XI [sai] (Japan) (Demo 2)" Successfully verified 2 dumps
Unsure if that change would have any side effects since that temp dir should only have .bins from the single extracted .chd I think?
Ahh, awesome work figuring that out @Z-95! I see that the underlying filename matching module fnmatch supports escaping parts of the pattern and from a quick test it looks like it'll work if the brackets are escaped. Thanks very much!