Repository navigation
Force LF on the mapping TSVs whose hashes tests check - #24
Open
s28ale-maker wants to merge 1 commit into
Open
s28ale-maker wants to merge 1 commit into
s28ale-maker wants to merge 1 commit into
Conversation
tests/test_benchmark_reserve.py compares the SHA-256 of mappings/soulcap_entities.tsv and mappings/curated_mappings.tsv against the values frozen in mappings/benchmark_reserve.json. On Windows with core.autocrlf=true those files check out with CRLF, the bytes change, and the test fails locally even though CI (LF) passes. Pin them to eol=lf. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Summary
Adds a
.gitattributesthat pins two files to LF line endings:tests/test_benchmark_reserve.pychecks the SHA-256 of both files against the values frozen inmappings/benchmark_reserve.json. On Windows withcore.autocrlf=true, Git checks them out with CRLF line endings, which changes the bytes, so the test fails locally even though the committed content is correct and CI (Linux, LF) passes.The committed file content doesn't change. Only how Windows checkouts write the files changes.
mappings/arrives with part 6 of the stack (#20); a rule for a path that doesn't exist yet is harmless.After merging: refresh your local copies once
Git doesn't rewrite files already checked out, so re-check-out the two files once.
Bash / Git Bash:
rm mappings/soulcap_entities.tsv mappings/curated_mappings.tsv && git checkout -- mappings/PowerShell:
Test plan
pr-09-species-pilot) on Windows withcore.autocrlf=true: both files check out LF andtests/test_benchmark_reserve.pypasses. Without this file, it fails with a hash mismatch.main):uv run pytestpasses with UTF-8 mode (121 passed, 94.5% coverage), anduv run ruff check .passes. Two tests onmainfail locally on Windows because of a missingencoding="utf-8", which Add soulcap-lookup, soulcap-tokens, type checking, and CI improvements #15 fixes; they're unrelated to this change.🤖 Generated with Claude Code