unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
* bug#48313: [1.3.0rc2] ‘guix describe’ prints nothing and exits with 0
@ 2021-05-09 14:34 Ludovic Courtès
  2021-05-09 14:47 ` Ludovic Courtès
  2021-05-09 21:51 ` Ludovic Courtès
  0 siblings, 2 replies; 4+ messages in thread
From: Ludovic Courtès @ 2021-05-09 14:34 UTC (permalink / raw)
  To: 48313; +Cc: Maxim Cournoyer

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’.




^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#48313: [1.3.0rc2] ‘guix describe’ prints nothing and exits with 0
  2021-05-09 14:34 bug#48313: [1.3.0rc2] ‘guix describe’ prints nothing and exits with 0 Ludovic Courtès
@ 2021-05-09 14:47 ` Ludovic Courtès
  2021-05-09 21:51 ` Ludovic Courtès
  1 sibling, 0 replies; 4+ messages in thread
From: Ludovic Courtès @ 2021-05-09 14:47 UTC (permalink / raw)
  To: 48313; +Cc: Maxim Cournoyer

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.

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:

--8<---------------cut here---------------start------------->8---
(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)))))))
--8<---------------cut here---------------end--------------->8---

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

Ludo’.




^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#48313: [1.3.0rc2] ‘guix describe’ prints nothing and exits with 0
  2021-05-09 14:34 bug#48313: [1.3.0rc2] ‘guix describe’ prints nothing and exits with 0 Ludovic Courtès
  2021-05-09 14:47 ` Ludovic Courtès
@ 2021-05-09 21:51 ` Ludovic Courtès
  2021-05-10  0:46   ` Maxim Cournoyer
  1 sibling, 1 reply; 4+ messages in thread
From: Ludovic Courtès @ 2021-05-09 21:51 UTC (permalink / raw)
  To: 48313-done; +Cc: Maxim Cournoyer

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

and so on.

Ludo’.




^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#48313: [1.3.0rc2] ‘guix describe’ prints nothing and exits with 0
  2021-05-09 21:51 ` Ludovic Courtès
@ 2021-05-10  0:46   ` Maxim Cournoyer
  0 siblings, 0 replies; 4+ messages in thread
From: Maxim Cournoyer @ 2021-05-10  0:46 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: 48313-done

Hi!

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

> 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




^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2021-05-10  0:47 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-09 14:34 bug#48313: [1.3.0rc2] ‘guix describe’ prints nothing and exits with 0 Ludovic Courtès
2021-05-09 14:47 ` Ludovic Courtès
2021-05-09 21:51 ` Ludovic Courtès
2021-05-10  0:46   ` Maxim Cournoyer

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).