Skip to content

Find a Project VIC file whose name differs only in case or composition - #327

Merged
abrignoni merged 1 commit into
mainfrom
fix/vic-locator-case-insensitive
Oct 30, 2026
Merged

abrignoni merged 1 commit into
mainfrom
fix/vic-locator-case-insensitive

Conversation

@abrignoni

Copy link
Copy Markdown
Owner

A Project VIC entry whose name differs from the file on disk only in case, or in how an accented letter is composed, was reported missing on macOS after #322. Before #322 it was found.

  • The folder listing is matched with os.path.normcase, which folds case only on Windows. A name that matches a listed one loosely is now checked against the filesystem, which decides.
  • test_a_name_in_another_case_takes_the_disks_spelling failed on main on macOS and passes now. Four new tests fake the listing so every platform runs the fallback; three of them fail on main.
  • Reading 16,000 entries takes the same time.

🤖 Generated with Claude Code

#322 found each entry's file in one listing per folder, matched with
os.path.normcase, which folds case only on Windows. On a Mac volume, and on
FAT or exFAT anywhere, a name that differs from the disk's in case or in how
an accented letter is composed is the same file, and Path.exists found it
before #322; the listing called it missing. A name that matches a listed one
only loosely is now asked of the filesystem. A name with no loose match costs
nothing more: 16,000 entries read in the same 139 to 142 ms.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@abrignoni
abrignoni enabled auto-merge October 30, 2026 22:11
@abrignoni
abrignoni merged commit aa53061 into main Oct 30, 2026
7 checks passed
@abrignoni
abrignoni deleted the fix/vic-locator-case-insensitive branch October 31, 2026 01:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant