GNU bug report logs - #58567
Grafting affects origins

Previous Next

Package: guix;

Reported by: Marius Bakke <marius <at> gnu.org>

Date: Sun, 16 Oct 2022 17:08:02 UTC

Severity: important

Done: Ludovic Courtès <ludo <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Marius Bakke <marius <at> gnu.org>
To: zimoun <zimon.toutoune <at> gmail.com>, 58567 <at> debbugs.gnu.org
Subject: bug#58567: Some grafts use a different input derivation than computed by --no-grafts
Date: Mon, 17 Oct 2022 13:36:21 +0200
[Message part 1 (text/plain, inline)]
zimoun <zimon.toutoune <at> gmail.com> skriver:

> Hi Marius,
>
> I reminds me this [1].
>
> 1: <https://yhetil.org/guix/874jy87gcl.fsf <at> gmail.com>

Not sure if it's the same problem, but it is weird.  On 3d8c243efb615c7:

  $ guix build mesa
  /gnu/store/ccf705wvh0w224d6nyscnwlhqr04agk7-mesa-21.3.8-bin
  /gnu/store/vcmxgmmhwr39gwwnz7ljkhcg1bmq2r5z-mesa-21.3.8
  $ guix build --no-grafts mesa
  /gnu/store/grh2142hg6l5g5xav2di7rr1pwbg9m38-mesa-21.3.8-bin
  /gnu/store/sdzfljm6san79pqiy42yp0nzmkr2bafc-mesa-21.3.8
  $ guix size icecat | grep mesa
  /gnu/store/sdzfljm6san79pqiy42yp0nzmkr2bafc-mesa-21.3.8            411.6   169.6  11.6%
  $ guix size $(guix build --no-grafts icecat) | grep mesa
  /gnu/store/sdzfljm6san79pqiy42yp0nzmkr2bafc-mesa-21.3.8            411.6   169.6  11.6%

Should not the mesa used by icecat be the same as `guix build mesa`,
just like in the ungrafted case?  Their outputs differ, too:

  $ guix hash -r $(guix build mesa | tail -n1)
  1invy9jcd1fnfx7d4asfyjqs1jn7lngjfqswak6sy9ffjbhhsg6x
  $ guix hash -r $(guix size icecat | grep mesa | awk '{ print $1 }')
  195zk0c0h5m016hp0c1haqws47rwfj7sbpqpddmwk2iw402p3apv

Diffoscope says it will take 123 days to process these, so don't hold
your breath!

> On dim., 16 oct. 2022 at 19:35, Marius Bakke <marius <at> gnu.org> wrote:
>
>> It works for 'python-patiencediff', but fails for 'python-patch-ng',
>> both of which have no dependencies other than Python; but one uses
>> url-fetch and the other git-fetch.
>
> I guess that
>
>    guix build python-patch-ng -d
>
> uses a grafted git-minimal and propagates it, whereas
>
>    guix build python-patch-ng -d --no-grafts
>
> uses a non-grafted git-minimal.  Well, something like that. :-)

Indeed.

> Well, it is the same checkout output:
>
> --8<---------------cut here---------------start------------->8---
> $ guix build \
>    /gnu/store/7bcypqy80bz8ygi4880dxdj8vzcsvhdf-python-patch-ng-1.17.4-checkout.drv \
>    /gnu/store/ivbkmnl6md7lzf275nvqwdh6lc924hal-python-patch-ng-1.17.4-checkout.drv
> /gnu/store/jddbmm7nxhv9sl84j1jlsdy5iiwjpbiy-python-patch-ng-1.17.4-checkout
> /gnu/store/jddbmm7nxhv9sl84j1jlsdy5iiwjpbiy-python-patch-ng-1.17.4-checkout
> --8<---------------cut here---------------end--------------->8---

That's guaranteed since these derivations are "fixed-output" (notice the
r:sha256 property in the beginning of the file).  If they had any other
output the daemon would throw a failure.

The bug here is that Guix treats grafted origins as different, even
though their outputs are known in advance.

Probably the grafting machinery should ignore fixed-output derivations
somehow?
[signature.asc (application/pgp-signature, inline)]

This bug report was last modified 2 years and 275 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.