darwin case hack is busted #332
Labels
No labels
Affects/CppNix
Affects/Nightly
Affects/Only nightly
Affects/Stable
Area/build-packaging
Area/cli
Area/evaluator
Area/fetching
Area/flakes
Area/language
Area/lix ci
Area/nix-eval-jobs
Area/profiles
Area/protocol
Area/releng
Area/remote-builds
Area/repl
Area/repl/debugger
Area/store
bug
Context
contributors
Context
drive-by
Context
maintainers
Context
RFD
crash 💥
Cross Compilation
devx
docs
Downstream Dependents
E/easy
E/hard
E/help wanted
E/reproducible
E/requires rearchitecture
imported
Language/Bash
Language/C++
Language/NixLang
Language/Python
Language/Rust
Needs Langver
OS/Linux
OS/macOS
performance
regression
release-blocker
stability
Status
blocked
Status
invalid
Status
postponed
Status
wontfix
testing
testing/flakey
Topic/Large Scale Installations
ux
No milestone
No project
No assignees
3 participants
Notifications
Due date
No due date set.
Depends on
#428 Move the default build-dir to
/nix/var/tmp
lix-project/lix
Reference: lix-project/lix#332
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
the way nix extracts nars on darwin (since
276a40b31f
) may append~nix~case~hack~.*
strings to paths during extraction, silently fucking up the extracted store path. even worse, during dumping of store paths such suffixes are removed even when they weren't added for disambiguation, which lets us produce invalid nars:gives
we should remove the case hack nonsense, print a loud diagnostic when extracting nars that would require it asking the user to make their nix store cases-sensitive, and maybe even apply case-sensitive settings from the installer.
Arguably the original reason this was added was because /nix used to be on the root partition which is of course hard to make case sensitive. But we could make the store case sensitive in the installer now that it's a separate APFS container, and then just refuse to do these. We just have to figure out if you can retroactively make a container case sensitive.
Thinking harder about this: we cannot fix existing containers either online or offline. Though it's true that case sensitivity is an attribute in the superblock, there's hash maps in the fs that would be probably invalidated by tampering it.
I think the solution here is to make a
nix doctor apfs --fix
that copies to a new container.This issue was mentioned on Gerrit on the following CLs:
One bug found while bootstrapping: https://github.com/mesonbuild/meson/pull/13349
/nix/var/tmp
equiv nix bug: https://github.com/NixOS/nix/issues/10746
Taking notes here on how we can maybe migrate existing systems: https://pad.lix.systems/lix-casehack