behaviour of copy to ssh-ng remote confusing ('substitute-on-destination' vs 'builders-use-substitutes') #317

Closed
opened 2024-05-15 14:26:41 +00:00 by yu-re-ka · 3 comments
Member

Describe the bug

Using the nix3 copy command to copy to an ssh-ng host will ignore the substitute-on-destination option and instead look at the builders-use-substitutes option, which is very confusing.

Steps To Reproduce

  1. Attempt to use nix copy with substitute-on-destination to an ssh-ng remote destination
  2. Observe that it does not substitute on destination
  3. set --no-substitute-on-destination --builders-use-substitutes
  4. Observe that it now uses substitutes on the remote despite the --no-substitute-on-destination

Expected behavior

substitute-on-destination should be respected for nix copy operations while builders-use-substitutes should be respected for remote builders

nix --version output

nix (Lix, like Nix) 2.90.0-lixpre20240505-47fb494

Additional context

This was first encountered in CppNix around a year ago, and this workaround was added in colmena: beb157dcb6

## Describe the bug Using the nix3 copy command to copy to an ssh-ng host will ignore the substitute-on-destination option and instead look at the builders-use-substitutes option, which is very confusing. ## Steps To Reproduce 1. Attempt to use nix copy with substitute-on-destination to an ssh-ng remote destination 2. Observe that it does not substitute on destination 3. set --no-substitute-on-destination --builders-use-substitutes 4. Observe that it now uses substitutes on the remote despite the --no-substitute-on-destination ## Expected behavior `substitute-on-destination` should be respected for `nix copy` operations while `builders-use-substitutes` should be respected for remote builders ## `nix --version` output nix (Lix, like Nix) 2.90.0-lixpre20240505-47fb494 ## Additional context This was first encountered in CppNix around a year ago, and this workaround was added in colmena: https://github.com/zhaofengli/colmena/commit/beb157dcb68d9c620673c134a647cc1ad3f414f7
yu-re-ka added the
bug
label 2024-05-15 14:26:41 +00:00
qyriad added the
ux
Area/store
labels 2024-05-15 18:22:26 +00:00
Owner

Wow that is incredibly confusing! wtf!

Wow that is *incredibly* confusing! wtf!
Member

I think this change is already in Lix? 64a269ef73

(I noticed that because I relied on the old behavior :D)

I think this change is already in Lix? https://git.lix.systems/lix-project/lix/commit/64a269ef73b111d49037812bd899b5cb883158ef (I noticed that because I relied on the old behavior :D)
Author
Member

Oh whoops! then I didn't say anything (I had actually just searched for existing issues about this)

Oh whoops! then I didn't say anything (I had actually just searched for existing issues about this)
Sign in to join this conversation.
No milestone
No project
No assignees
3 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: lix-project/lix#317
No description provided.