[core-updates] 'guix pull' and './pre-inst-env' produces different derivations

  • Done
  • quality assurance status badge
Details
3 participants
  • Ludovic Courtès
  • Marius Bakke
  • Timothy Sample
Owner
unassigned
Submitted by
Marius Bakke
Severity
normal
M
M
Marius Bakke wrote on 24 Feb 2020 22:33
(address . bug-guix@gnu.org)
87a7574qnf.fsf@devup.no
Hello,

There is a strange bug on the core-updates branch: if you 'guix pull
--branch=core-updates', everything from around 'guile-bootstrap@2.0' in
the package graph will have different derivations from what you get in
the git checkout:

On my local fork of core-updates:

./pre-inst-env guix build -d bash
/gnu/store/y834q3sf056hkglpli4gr3ijmpvgzb7c-bash-5.0.16.drv

After 'guix pull -p /tmp/core-updates --url=/my/checkout
--branch=core-updates', on the same commit:

/tmp/core-updates/bin/guix build -d bash
/gnu/store/m3q1w669f7br5cs4admdy5p8rijrjmvp-bash-5.0.16.drv

I believe this is a recent regression (probably the wip-bootstrap
changes?), as I've pulled (and reconfigured) on the branch before.

Any idea what is going on here?
-----BEGIN PGP SIGNATURE-----

iQEzBAEBCgAdFiEEu7At3yzq9qgNHeZDoqBt8qM6VPoFAl5UQRQACgkQoqBt8qM6
VPrpjwgApwmHqMlSMkmUviPZGeOkLqbXNMj2++7T/QQZLAxqWi5kQ8VdQ6eIxnF7
MU1VnrCo94tvIE1ozHJmlm2FlHymwXUqtbd+3vNrtDkv+CcknasUf0qYujYLc7V5
G87M+d5gy/j1kG2ibrmaDS2OONIP/Ujl/HxbaOR6U7CeXKkYFN9MpQKzUV/hW9WI
LXUAZyor4SRi0dWQyTpTCUE2BGzD5IloNN0TdJoFG1Gk+m2GGIwq8uSigchfCf57
xG3mWJetXjyWHYOkpGSrlwIw1120avmdURALoqQjult1ihv7NwIAEqYxyWeOQvDb
VTh2jkiqWPc+JebHD6N8cWPekhd/1g==
=RaJ8
-----END PGP SIGNATURE-----

M
M
Marius Bakke wrote on 2 Mar 2020 19:14
(address . 39771@debbugs.gnu.org)(name . Timothy Sample)(address . samplet@ngyro.com)
87imjmk4ip.fsf@devup.no
Marius Bakke <mbakke@fastmail.com> writes:

Toggle quote (18 lines)
> Hello,
>
> There is a strange bug on the core-updates branch: if you 'guix pull
> --branch=core-updates', everything from around 'guile-bootstrap@2.0' in
> the package graph will have different derivations from what you get in
> the git checkout:
>
> On my local fork of core-updates:
>
> ./pre-inst-env guix build -d bash
> /gnu/store/y834q3sf056hkglpli4gr3ijmpvgzb7c-bash-5.0.16.drv
>
> After 'guix pull -p /tmp/core-updates --url=/my/checkout
> --branch=core-updates', on the same commit:
>
> /tmp/core-updates/bin/guix build -d bash
> /gnu/store/m3q1w669f7br5cs4admdy5p8rijrjmvp-bash-5.0.16.drv

I've tracked this down to 'gash-boot'. Namely the use of ,(version): it
evaluates to '2.2.6' when run with ./pre-inst-env and "3.0.0" after
'guix pull'.

I suspect both are wrong, and that it really intends to use the version
of gash here. Timothy, can you confirm?

Currently trying to 'guix pull' with a hard coded "2.2.6" version to
see if other instances need changing.
-----BEGIN PGP SIGNATURE-----

iQEzBAEBCgAdFiEEu7At3yzq9qgNHeZDoqBt8qM6VPoFAl5dTR4ACgkQoqBt8qM6
VPpvjwgAq8xf5UVSPsQ0vpuu2F5rXql6sgHXHI7RsM0Iq3QeHgYl4dI+h3rOBNpy
GkhUe59KfBoqHjDPiRo3xZ6AnzdcO0PnXtC0qfmEyPvZeMTM+p+gxNIf4vwZMCNU
dVm7o+CgAFdGgKfzjIojYjDaxEWxVu2MOdhLtd4dYR33RpKTWDXWk8jwXYoTXcDK
96xS056hHF8cvY3jutuATyJv02mteu7KEexsa31G5yPb3bYG8oeYiLbiBPj5Dhea
t8Prxe6TP2evH5YKQeT11Ga0uBvVjNrkYz54z12uPnAjOXC2BUVeZ2UCiStvpvIy
2B8Zz/stmMTdKkIvJyDzaNC1zR/gNA==
=oce6
-----END PGP SIGNATURE-----

M
M
Marius Bakke wrote on 2 Mar 2020 21:23
(address . 39771@debbugs.gnu.org)(name . Timothy Sample)(address . samplet@ngyro.com)
87d09ujykb.fsf@devup.no
Marius Bakke <mbakke@fastmail.com> writes:

Toggle quote (30 lines)
> Marius Bakke <mbakke@fastmail.com> writes:
>
>> Hello,
>>
>> There is a strange bug on the core-updates branch: if you 'guix pull
>> --branch=core-updates', everything from around 'guile-bootstrap@2.0' in
>> the package graph will have different derivations from what you get in
>> the git checkout:
>>
>> On my local fork of core-updates:
>>
>> ./pre-inst-env guix build -d bash
>> /gnu/store/y834q3sf056hkglpli4gr3ijmpvgzb7c-bash-5.0.16.drv
>>
>> After 'guix pull -p /tmp/core-updates --url=/my/checkout
>> --branch=core-updates', on the same commit:
>>
>> /tmp/core-updates/bin/guix build -d bash
>> /gnu/store/m3q1w669f7br5cs4admdy5p8rijrjmvp-bash-5.0.16.drv
>
> I've tracked this down to 'gash-boot'. Namely the use of ,(version): it
> evaluates to '2.2.6' when run with ./pre-inst-env and "3.0.0" after
> 'guix pull'.
>
> I suspect both are wrong, and that it really intends to use the version
> of gash here. Timothy, can you confirm?
>
> Currently trying to 'guix pull' with a hard coded "2.2.6" version to
> see if other instances need changing.

This patch solves the problem without triggering a full rebuild:
Toggle diff (22 lines)
diff --git a/gnu/packages/commencement.scm b/gnu/packages/commencement.scm
index cfbb5e3bff..0d5bfa4dfa 100644
--- a/gnu/packages/commencement.scm
+++ b/gnu/packages/commencement.scm
@@ -151,7 +151,7 @@ pure Scheme to Tar and decompression in one easy step.")
(use-modules (guix build gnu-bootstrap))
(modify-phases %standard-phases
(replace 'configure
- (bootstrap-configure ,(version) "gash" "scripts"))
+ (bootstrap-configure "2.2.6" "gash" "scripts"))
(replace 'build (bootstrap-build "gash"))
(replace 'install (bootstrap-install "gash" "scripts"))
(add-after 'install 'install-symlinks
@@ -214,7 +214,7 @@ pure Scheme to Tar and decompression in one easy step.")
(delete-file "scripts/template.in")
#t))
(replace 'configure
- (bootstrap-configure ,(version) "gash" "scripts"))
+ (bootstrap-configure "2.2.6" "gash" "scripts"))
(replace 'build (bootstrap-build "gash"))
(replace 'install (bootstrap-install "gash" "scripts"))
;; XXX: The scripts should add Gash to their load paths and
I have another full-rebuild commit in the pipeline (bzip2 currently
keeps a reference to the Mes toolchain), so we might as well fix it
properly.

Waiting for confirmation from Timothy as to what the proper fix is,
though.
-----BEGIN PGP SIGNATURE-----

iQEzBAEBCgAdFiEEu7At3yzq9qgNHeZDoqBt8qM6VPoFAl5da0QACgkQoqBt8qM6
VPoJmggAvH2TdXhyvF5Jw6sPJIjkBmXQSzdkfdWWpK1Uz3aXRIcJIkbxOhxxguMc
7Y+o4rwJKrw6Nf/fDcxl+PPCZ2ozVpa5/jYjOFAwJ3u8TzsxMl1/Emn+/8Dr0Ndp
//44GMNKQTY+TYz57vxYaBKgRu2yNhc3pmuquvfyQvnEqVbrJ8lEyB4k0c/HhA00
S3pbyaPANM6MfN6sMkHwcLt3G6aN6cplpH3kM+QwGfBFTWdtM65cChb9xrilyMsu
ffNbqc6p9EqKT4hRBXLoOHTH2rUK1emfo2C6AneVpLeMTXo/+b8+DBhG5E5r9fql
pwqB78K/+jRSsepSrHd+sSmvbpB6VA==
=6Z3c
-----END PGP SIGNATURE-----

T
T
Timothy Sample wrote on 3 Mar 2020 00:11
(name . Marius Bakke)(address . mbakke@fastmail.com)(address . 39771-done@debbugs.gnu.org)
87pnduwdvn.fsf@ngyro.com
Hi Marius,

Marius Bakke <mbakke@fastmail.com> writes:

Toggle quote (10 lines)
> Marius Bakke <mbakke@fastmail.com> writes:
>
>>
>> I've tracked this down to 'gash-boot'. Namely the use of ,(version): it
>> evaluates to '2.2.6' when run with ./pre-inst-env and "3.0.0" after
>> 'guix pull'.
>>
>> I suspect both are wrong, and that it really intends to use the version
>> of gash here. Timothy, can you confirm?

Definitely wrong! I think I had somehow convinced myself that the
version of Gash was available when inheriting but delayed via a thunk.
The fact that it happily returns the current Guile version means that I
never noticed how wrong I was. Sorry!

Toggle quote (14 lines)
>> Currently trying to 'guix pull' with a hard coded "2.2.6" version to
>> see if other instances need changing.
>
> This patch solves the problem without triggering a full rebuild:
>
> [...]
>
> I have another full-rebuild commit in the pipeline (bzip2 currently
> keeps a reference to the Mes toolchain), so we might as well fix it
> properly.
>
> Waiting for confirmation from Timothy as to what the proper fix is,
> though.

It should be using “package-version” to get the versions from the parent
packages. Fixed in 0b870f7915f5da43758753fd088a22033936dc50.


-- Tim
Closed
L
L
Ludovic Courtès wrote on 8 Mar 2020 21:59
Re: bug#39771: [core-updates] 'guix pull' and './pre-inst-env' produces different derivations
(address . 39771@debbugs.gnu.org)
87eeu28swf.fsf@gnu.org
Hi!

Timothy Sample <samplet@ngyro.com> skribis:

Toggle quote (3 lines)
> It should be using “package-version” to get the versions from the parent
> packages. Fixed in 0b870f7915f5da43758753fd088a22033936dc50.

Alternately, you can write:

(arguments
`(… ,(package-version this-package) …))

so that the version number remains correct when inheriting
(‘this-package’ is a self reference.)

Ludo’.
?