[1.3.0rc2] ‘guix describe’ prints nothing and exits with 0

  • Done
  • quality assurance status badge
Details
2 participants
  • Ludovic Courtès
  • Maxim Cournoyer
Owner
unassigned
Submitted by
Ludovic Courtès
Severity
important
L
L
Ludovic Courtès wrote on 9 May 2021 16:34
[1.3.0rc2] ‘guix describe’ prints nothing and exits with 0
(address . bug-guix@gnu.org)
87pmy06kny.fsf@inria.fr
In the 1.3.0rc2 VM image, ‘guix describe’ prints nothing and exits with
0 (success). This is with /run/current-system/profile/bin/guix.
‘strace’ shows that it parses /run/current-system/profile/manifest,
which does not contain provenance information.

“$(readlink -f $(type -P guix)) describe” prints what’s expected, with
information from (guix config).

This is a regression compared to 1.3.0rc1.

Ludo’.
L
L
Ludovic Courtès wrote on 9 May 2021 16:40
control message for bug #48313
(address . control@debbugs.gnu.org)
87o8dk6kdm.fsf@gnu.org
severity 48313 important
quit
L
L
Ludovic Courtès wrote on 9 May 2021 16:40
control message for bug #47297
(address . control@debbugs.gnu.org)
87mtt46kd7.fsf@gnu.org
block 47297 by 48313
quit
L
L
Ludovic Courtès wrote on 9 May 2021 16:47
Re: bug#48313: [1.3.0rc2] ‘guix describe ’ prints nothing and exits with 0
(address . 48313@debbugs.gnu.org)(name . Maxim Cournoyer)(address . maxim.cournoyer@gmail.com)
87fsyw6k0w.fsf@gnu.org
Ludovic Courtès <ludo@gnu.org> skribis:

Toggle quote (5 lines)
> In the 1.3.0rc2 VM image, ‘guix describe’ prints nothing and exits with
> 0 (success). This is with /run/current-system/profile/bin/guix.
> ‘strace’ shows that it parses /run/current-system/profile/manifest,
> which does not contain provenance information.

In RC1, ‘current-profile’ from (guix describe) returns #f.
Thus, ‘current-channels’ returns channel metadata from (guix config).

In RC2, ‘current-profile’ returns /run/current-system/profile.
Thus, ‘current-channels’ returns metadata from profile entries, but
there’s none.

The different ‘current-profile’ behavior stems from this condition:

Toggle snippet (16 lines)
(define current-profile
(mlambda ()
"Return the profile (created by 'guix pull') the calling process lives in,
or #f if this is not applicable."
(match initial-program-arguments
((program . _)
(and (string-suffix? "/bin/guix" program) ;<------ HERE!
;; Note: We want to do _lexical dot-dot resolution_. Using ".."
;; for real would instead take us into the /gnu/store directory
;; that ~/.config/guix/current/bin points to, whereas we want to
;; obtain ~/.config/guix/current.
(let ((candidate (dirname (dirname program))))
(and (file-exists? (string-append candidate "/manifest"))
candidate)))))))

Prior to c47f3fc13562d82edfd2d47342574154c452843a, PROGRAM was
“.guix-real” (hence the #f return value), but now it’s “guix”.

Ludo’.
L
L
Ludovic Courtès wrote on 9 May 2021 23:51
(address . 48313-done@debbugs.gnu.org)(name . Maxim Cournoyer)(address . maxim.cournoyer@gmail.com)
874kfb7ezl.fsf@gnu.org
Ludovic Courtès <ludo@gnu.org> skribis:

Toggle quote (5 lines)
> In the 1.3.0rc2 VM image, ‘guix describe’ prints nothing and exits with
> 0 (success). This is with /run/current-system/profile/bin/guix.
> ‘strace’ shows that it parses /run/current-system/profile/manifest,
> which does not contain provenance information.

Fixed in 8a154c29151fc445e8d0364f507f6e200de1e700. (I tested with ‘make
update-guix-package’ from which I built a VM to test into.)

The bug would also cause ‘guix pull’ to start authentication at the
introductory commit (thus authenticating more than 17,000 commits)
instead of starting at the current commit (around 800 commits today.)

If anyone wants to double-check, you can run, on version-1.3.0:

make update-guix-package
./pre-inst-env guix system vm gnu/system/examples/vm-image.tmpl

and from there try things like:

guix describe
guix pull

and so on.

Ludo’.
Closed
M
M
Maxim Cournoyer wrote on 10 May 2021 02:46
(name . Ludovic Courtès)(address . ludo@gnu.org)(address . 48313-done@debbugs.gnu.org)
87r1ifv2iv.fsf@gmail.com
Hi!

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

Toggle quote (24 lines)
> Ludovic Courtès <ludo@gnu.org> skribis:
>
>> In the 1.3.0rc2 VM image, ‘guix describe’ prints nothing and exits with
>> 0 (success). This is with /run/current-system/profile/bin/guix.
>> ‘strace’ shows that it parses /run/current-system/profile/manifest,
>> which does not contain provenance information.
>
> Fixed in 8a154c29151fc445e8d0364f507f6e200de1e700. (I tested with ‘make
> update-guix-package’ from which I built a VM to test into.)
>
> The bug would also cause ‘guix pull’ to start authentication at the
> introductory commit (thus authenticating more than 17,000 commits)
> instead of starting at the current commit (around 800 commits today.)
>
> If anyone wants to double-check, you can run, on version-1.3.0:
>
> make update-guix-package
> ./pre-inst-env guix system vm gnu/system/examples/vm-image.tmpl
>
> and from there try things like:
>
> guix describe
> guix pull

Thanks for catching & fixing this!

Maxim
Closed
?
Your comment

This issue is archived.

To comment on this conversation send an email to 48313@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 48313
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch