fix: clarify misleading SHA mismatch error message#209
Merged
Conversation
The error thrown when plain files have mismatched SHAs claimed it covered all "non-binary files", but the check only iterates over AppFileType.PLAIN files. Reword the message to accurately describe the files actually compared. Fixes #103
MarshallOfSound
approved these changes
Jun 28, 2026
erikian
approved these changes
Jun 28, 2026
|
🎉 This PR is included in version 3.0.5 🎉 The release is available on: Your semantic-release bot 📦🚀 |
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.
Requested by Samuel Attard · Slack thread
This reword fixes the misleading error message reported in #103.
Before: when a file's SHA differed between the x64 and arm64 builds, the error read:
The phrase "non-binary files" is inaccurate. As the issue notes, the scope of this check widened over time. The loop only iterates over
AppFileType.PLAINfiles — the catch-all category for anything that is not a Mach-O binary, a.binV8 snapshot, anInfo.plist, or an ASAR archive. APLAINfile can still contain binary data, so "non-binary" misdescribes what is actually compared.After: the message now names the actual set of files the check covers:
How: the SHA-equality loop in
src/index.tsis already correctly scoped (multiArchFiles.filter((f) => f.type === AppFileType.PLAIN)), so no behavior change was needed — only the error string was reworded to match what the code does. This is a one-line change.Fixes #103
Generated by Claude Code