chore: normalize CSVs to LF + enforce in CI - #42
Merged
Conversation
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.
Normalize every tracked CSV to LF line endings with a final newline, and enforce it in CI.
Why
The hub's contribution-submit feature (see resslab-hub-data#41) re-serializes the primary CSV with LF endings when appending contributed rows. Five of the nine primary CSVs were stored with CRLF, so every contribution PR showed the entire file — header included — as changed, making diffs unreviewable and guaranteeing conflicts between concurrent contributions.
What
chore: normalize all CSVs to LF line endings with final newlines— 1,167 files: 1,165 CRLF→LF, 159 missing final newlines added (157 overlap). Verified:git diff --ignore-cr-at-eolagainst the base is completely empty, i.e. zero content changes; all 9 primary CSVs now round-trip byte-identically through the backend's submission serializer, so future contribution diffs are exactly the appended rows.ci: enforce LF + final newline on CSVs—.gitattributesgains*.csv text eol=lf(git clients auto-normalize on commit), anddata-validation.ymlgains an unconditionalline-endingsjob (fails on any CR in a tracked CSV or any missing final newline) as the backstop for web uploads and API commits, which bypass.gitattributes.Merging notes
[skip ci]in the commit title — e.g.chore: normalize CSVs to LF + enforce in CI [skip ci]. Otherwiseci.ymlre-uploads ~1,165 unchanged files to the prod database..git-blame-ignore-revscontaining the squashed commit's SHA (it can't be known before the squash), so GitHub blame andgit blameskip this commit.