-
-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bps patching bug #806
Comments
I think I've been seeing some BPS issues with my collection as well, I'll try to investigate. As an aside, BPS patches have the source file's CRC32 in them, you don't need to put it in your patch filename 🙂. https://igir.io/roms/patching/#rom-checksums has the docs on this. |
@Mihara this log indicates there is already a file in your output directory, and that you did not provide the
If that file is not runnable then it's the fault of some other process. Given the patch file you linked, I was able to successfully patch the ROM: $ npm start -- copy zip clean --input "Downloads/46 Okunen Monogatari - Harukanaru Eden e (Japan).7z" --patch "Downloads/46 Okunen Monogatari - Harukanaru Eden e (Japan) (En)(Retranslation, EVO - Search for Eden)(RH5486) B090235A.bps" --output temp
______ ______ ______ _______
| \ / \ | \| \
\$$$$$$| $$$$$$\ \$$$$$$| $$$$$$$\
| $$ | $$| \ | $$ | $$ $$ ROM collection manager
| $$ | $$| \ | $$ | $$ $$ https://igir.io/
| $$ | $$ \$$$$ | $$ | $$$$$$$\
_| $$_ | $$__| $$ _| $$_ | $$ | $$ v2.1.0
| $$ \ \$$ $$| $$ \| $$ | $$
\$$$$$$ \$$$$$$ \$$$$$$ \$$ \$$
WARN: No DAT files provided, consider using some for the best results!
✓ Scanning for ROMs ·········· | 1 file found
✓ Scanning for patches ······· | 1 unique patch found
✓ Downloads ·················· | 1 games, 1 retail releases, 1 patched games written
✓ Cleaning output directory ·· | 1 file recycled
$ crc32 temp/*
1bab99c8 temp/46 Okunen Monogatari - Harukanaru Eden e (Japan) (En)(Retranslation, EVO - Search for Eden)(RH5486).zip
b1946ac7 temp/46 Okunen Monogatari - Harukanaru Eden e (Japan).zip |
If I have that, my script that applies them without igir doesn't have to know BPS to apply them.
This one doesn't, because I replicated the test case again in a clean environment and made sure to only run it once:
The resulting file still has a hash different from the one patched by flips, and it's still the same:
What next? |
@Mihara could you add So that I can try to reproduce, could you paste the CRC32 of those three files instead? BPS patches include an expected output CRC32 in them. |
Here. Initial setup: $ ls -1R
.:
known-good
patch
rom
runtest
./known-good:
'46 Okunen Monogatari - Harukanaru Eden e (Japan) (En)(Retranslation, EVO - Search for Eden)(RH5486).sfc'
./patch:
'46 Okunen Monogatari - Harukanaru Eden e (Japan) (En)(Retranslation, EVO - Search for Eden)(RH5486) B090235A.bps'
./rom:
'46 Okunen Monogatari - Harukanaru Eden e (Japan).zip'
Contents of #!/bin/bash
rm -rf rom-output igir.log
echo ==== IGIR OUTPUT ==== > igir.log
igir copy zip test -vvv --input rom --output rom-output --patch patch >> igir.log
echo ==== CRC32 ==== >> igir.log
crc32 known-good/* rom-output/* >> igir.log
find rom-output -name '*.zip' -exec unzip -v {} \; >> igir.log Results in igir.log:
Indeed, adding |
I'm able to reproduce it on my end.
|
🔒 Inactive issue lockThis issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. Comment generated by the GitHub Lock Issues workflow. |
Paste the command
That really shouldn't matter in this case, but if you insist.
Describe the bug
I have attempted to automatically apply a large number of translation patches, so far only to SNES roms, and immediately ran into a problem: IPS patch files acquired from RomHacking.net, while they do list a specific rom they apply to, do not necessarily work on the rom listed as is: sometimes, they expect a header, even though versions listed in the No-Intro database never have them.
After I realized that, I spent most of a day converting 200+ patches acquired from RomHacking to BPS, by creating a headered or unheadered rom as required, applying the IPS, verifying that the result runs, and creating a BPS from that, using flips for all the stages of the process except adding a rom header. (That, I just did with a python script that launched flips.)
That took most of a day, but now I have a large number of BPS patches that definitely work with the rom files I actually have.
When attempting to run igir on the lot, however, I get garbled and broken patches. When applying patches manually with flips, they work -- but most importantly, SHA1 hashes of the files patched with igir an patched with flips are different, and that means there's definitely a bug somewhere.
Here's an example .bps, I have a lot more of those if you need any.
sha1sum says:
The hash of the file produced by igir seems to be consistent, at least, but invariably, it's the flips patched copy that runs, while the igir patched copy doesn't.
Expected behavior
Patching should be consistent with other tools making BPS files. Failing that, flips could be in the wrong, in which case I need to file a bug report elsewhere, but I find this somewhat less likely.
Debug logs
Nothing of interest in there:
DAT(s) used
No response
igir version
v2.1.0
Node.js version
v20.8.1
Operating system
Ubuntu 22.04.3 LTS
Additional context
In addition, some of the zipped patched roms produced are missing file extensions -- dots in the middle of the filename are apparently involved -- and the rom name
G.O.D - Mezame yo to Yobu Koe ga Kikoe (Japan).zip
confuses the patcher enough that there's a strayO.zip
in the result.The text was updated successfully, but these errors were encountered: