-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
nix copies inputs already in the nix store #11228
Copy link
Copy link
Closed
Labels
bugfetchingNetworking with the outside (non-Nix) world, input lockingNetworking with the outside (non-Nix) world, input locking
Description
Describe the bug
I have this in the nix registry.json
{
"exact": true,
"from": {
"id": "nixpkgs",
"type": "indirect"
},
"to": {
"path": "/nix/store/<some path>",
"type": "path"
}
},
Running nix eval 'nixpkgs#hello.meta produces output "copying /nix/store/<some path>" every time.
I notice this does not always happen. It happens if the "path" points to something that is built. In this case, my nixpkgs source is built by calling applyPatches. It does not happen if the "path" points to something that is fetched directly. e.g. if I use inputs.nixpkgs.url = github.com:nixos/nixpkgs, then points "path" to inputs.nixpkgs, then nix eval does not copy.
Expected behavior
nix should not copy if the input is already in the nix store.
Priorities
Add 👍 to issues you find important.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugfetchingNetworking with the outside (non-Nix) world, input lockingNetworking with the outside (non-Nix) world, input locking