-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Global Channels and per-user profiles #7984
Comments
Edit from @Ericson2314: This is discussion is about the general issue with the release, not this specific channels issue in particular. My fussing with the team agenda caused these notes to land here somewhat inadvertently. Discussed in the Nix team meeting:
|
This issue has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/2023-03-06-nix-team-meeting-minutes-38/26056/1 |
I ran into exactly this issue as described, see https://stackoverflow.com/questions/75657834/fresh-install-of-nix-fails-on-m1-mac-error-attribute-nixpkgs-in-selection-pa Can I suggest a quick fix @fricklerhandwerk? The most affected people by this seem to be people who install for the first time. They will usually use recommended So why don't you change that install script to download 2.13 until you have figured out a way forward with 2.14? By the way, one workaround seems to be |
Yes, we talked about the more general solution of versioned installers recently, and I'm in favor of this. Need to prioritise it on the team though. @Ericson2314 do we have an issue for that? |
@fricklerhandwerk An issue for what, rolling back the default installer? I agree that is a good stop-gap. |
No, for providing versioned installers. We can always just roll back, but the interesting question is what to do next. |
So have you already rolled back the default installer? This should be a few clicks and save lots of people quite some hassle. I don't know how many people install nix but it'll be dozens a day and they may well be lost by this. |
Possibly related? #7992 |
We've reverted the installer to 2.13.3 for now. |
Discussed in the Nix team Meeting:
|
This issue has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/2023-03-10-nix-team-meeting-minutes-39/26279/1 |
#8073 fixed this. |
#8147 builds on this, but is just icing on the cake. |
This issue has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/sudo-nixos-rebuild-switch-upgrade-does-not-get-updates-anymore/27072/7 |
Describe the bug
I ran into trouble installing (a) Nix and then (b) home-manager on my friend's macOS machine. A bunch of similar issues have been reported, but I think this one is slightly different.
The problem is this:
nix/src/libexpr/eval.cc
Lines 2494 to 2495 in 19c1a46
these two lines neglect the fact that with the XDG profile dirs, these will instead be in
~root/.local/state/profiles/channels
.Steps To Reproduce
<nixpkgs>
nixpkgs
key defined via the Nix Path.Expected behavior
Global channels are usable with the default (no env var set) Nix path.
nix-env --version
outputnix-env (Nix) 2.14.1
Additional context
A simple fix would be to get the the default Nix path to try to look in
~root/.local/state/nix/profiles/channels
too, but I don't think that is the right solution. "per user" profiles (channels or otherwise) should be just for that user, which is why it is safe and correct to move them to~/.local/state/nix/profiles
. If channels are to be shared system wide, they are not a per-user concept, even a root user concept. Indeed, root-specific channels should be secret channels just for the root user.We have precedent of this: the default profile which has long been
$nixStateDir/profiles/default
not$nixStateDir/profiles/per-user/root
precisely for the same reason. We should simply reuse that same solution and havenixStateDir + profiles/default
or similar. Neither of these are effected by the XDG stuff because they are not per user, and this is correct.Priorities
Add 👍 to issues you find important.
The text was updated successfully, but these errors were encountered: