guix-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Guix pull: avoiding "Computing Guix derivation"


From: Edouard Klein
Subject: Re: Guix pull: avoiding "Computing Guix derivation"
Date: Tue, 14 May 2024 16:48:49 +0200
User-agent: mu4e 1.10.2; emacs 28.2

Hi !

I may be a bit dense, but there's one part I don't understand:

Ludovic Courtès <ludo@gnu.org> writes:

> Hi,
>
> Edouard Klein <edou@rdklein.fr> skribis:
>
>> - Why is this step not substitutable ? The inputs are known, a hash can
>> be derived, a substitute server could be queried for an output of that
>> hash ? What am I missing ? Does the guix derivation not end up in the
>> store ? What makes it so special that it can't be served by a substitute
>> server ?
>
> It’s not substitutable because it’s not a derivation.  It’s not a
> derivation because it needs to access the store to “compute the Guix
> derivation”.
>

Doesn't it have hashable inputs ? Like the different git hashes of the
different channels, plus the hash of whatever guix+guile revision is actually
doing the work ?

I think my misunderstanding boils down to a bad mental model of how guix
works.

What I imagine the "Computing guix derivation" step to be is no
different than building a package whose inputs are the channels'
sources, guile, and the current guix, and whose output is the new guix.

Simon and Richard pointed out that the combinatorial combination of all
possible input combination makes this hard to substitute, but I don't
understand how its result, once in the store, can't lead to a simple
linking from the profile to the store, instead of re-running the
"Computing guix derivation" step when guix pull is called with the same
inputs.

Surely my mental model is wrong somehow ?





> The latter could be addressed with “nested” or “recursive” derivations
> as Nix calls them, but it’s quite a beast.
>
> Anther option would be to have a built-in derivation builder that would
> do that process on behalf of users.  That would turn the process into a
> derivation, which is thus cachable, substitutable, etc.
>
>> - Is there a way (even a very dirty one, like hand copying stuff accross
>>   /var/guix/profiles/per-user/*/current-guix) I can stop paying this 4
>>   minutes per user price ? As I said, this is downtime on my server, as
>>   I need to stop all other services to let guix pull finish.
>
> I don’t know of any quick hack for that.
>
> Thanks,
> Ludo’.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]