fix(Import): case-fold media filenames when checking uniqueness#4435
Merged
abdnh merged 8 commits intoankitects:mainfrom Nov 20, 2025
Merged
fix(Import): case-fold media filenames when checking uniqueness#4435abdnh merged 8 commits intoankitects:mainfrom
abdnh merged 8 commits intoankitects:mainfrom
Conversation
|
MacOS APFS is also case-insensitive by default, wouldn't it be better to always case-fold? Syncing between different filesystems could be a problem too. |
Contributor
Author
Doesn't seem like it'd be easy to handle this retroactively (there's already some normalisation when syncing but it doesn't update media references afaict), will look into it. Maybe it can be done during For now i've added a change to case-fold when adding new media for consistency |
abdnh
approved these changes
Nov 20, 2025
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.
Fixes #4433
The fix proposed is to compare media filenames case-insensitively on windows only. Initially set it to case-fold all the time as i thought case-sensitivity was a filesystem property, but it seems windows allows per-directory case-sensitivity (still problematic as win32 programs usually expect case insensitive filenames)
Perhaps we could test for this at startup by touching two files whose names only differ by case and using same-file to check if they're considered the same in the media folder