unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
From: Adam Griffiths <adam.lw.griffiths@gmail.com>
To: "Ludovic Courtès" <ludo@gnu.org>
Cc: 43039@debbugs.gnu.org
Subject: bug#43039: Vanilla GUIX 1.1.0 reconfigure fails on nss-certs
Date: Sat, 29 Aug 2020 13:10:00 +1000	[thread overview]
Message-ID: <CAFgA=J6bETsaRYBNX9_GRqfGuRPeDezqScq0VZdYY3aAdz6MPA@mail.gmail.com> (raw)
In-Reply-To: <877dtiq30m.fsf@gnu.org>

Hey Ludo,

Thanks for getting back to me, responses are inline below.

FYI, I'm planning to format the host (Guix is inside VirtualBox) and
may not be able to assist for a period.
I literally just installed Guix into Virtual Box with the defaults,
selecting Australia / Melbourne where the option presented itself.
The only other change was enabling sshd, but regardless the issue
presents itself.
That should be enough to replicate, otherwise I'll be able to assist
further when I have my system back up.

Cheers,
Adam

> > $ sudo guix system reconfigure /etc/config.scm
> > <sudo warning snipped>
> > guile: warning: failed to install locale
> > hint: Consider installing the `glibc-utf8-locales' or `glibc-locales'
> > package and defining
> > `GUIX_LOCPATH', along these lines:
> >
> >      guix package -i glibc-utf8-locales
> >      export GUIX_LOCPATH="$HOME/.guix-profile/lib/locale"
> >
> > See the "Application Setup" section in the manual, for more info.
> >
> > guix system: warning: cannot determine provenance for current system
> > substitute: updating substitutes from 'https://ci.guix.gnu.org'... 100.0%
>
> That, I don’t understand.  I tried to reproduce it by downloading
> <https://ftp.gnu.org/gnu/guix/guix-system-vm-image-1.1.0.x86_64-linux.xz>
> (which is essentially the result of installing Guix System from 1.1.0).
> I ran ‘guix pull’ (which took a lot of time…) and then ‘guix system
> reconfigure’.  ‘guix system reconfigure’ would only emit the one-liner:
>
>   warning: failed to install locale
>
> and not the hint about GUIX_LOCPATH, and then it just went ahead.
>
> What locale does your system use?  You can type “env | grep LC_” to see.
>

I'm using en_AU

$ env | grep GUIX
GUIX_LOCPATH=/run/current-system/locale
GUIX_GTK3_PATH=/run/current-system/profile/lib/gtk-3.0
$ env | grep LC_
$

Here's my system configuration, it should be straight out of the installer.

adam@Hetzer ~$ cat /etc/config.scm
;; This is an operating system configuration generated
;; by the graphical installer.

(use-modules (gnu))
(use-service-modules desktop networking ssh xorg)

(operating-system
  (locale "en_AU.utf8")
  (timezone "Australia/Melbourne")
  (keyboard-layout (keyboard-layout "au"))
  (host-name "Hetzer")
  (users (cons* (user-account
                  (name "adam")
                  (comment "Adam Griffiths")
                  (group "users")
                  (home-directory "/home/adam")
                  (supplementary-groups
                    '("wheel" "netdev" "audio" "video")))
                %base-user-accounts))
  (packages
    (append
      (list (specification->package "nss-certs"))
      %base-packages))
  (services
    (append
      (list (service gnome-desktop-service-type)
            (service openssh-service-type)
            (set-xorg-configuration
              (xorg-configuration
                (keyboard-layout keyboard-layout))))
      %desktop-services))
  (bootloader
    (bootloader-configuration
      (bootloader grub-bootloader)
      (target "/dev/sda")
      (keyboard-layout keyboard-layout)))
  (swap-devices (list "/dev/sda2"))
  (file-systems
    (cons* (file-system
             (mount-point "/")
             (device
               (uuid "908e25d3-f03b-4808-8f1c-8f922e16408c"
                     'ext4))
             (type "ext4"))
           %base-file-systems)))


>
> (The ‘guix’ command provided by ‘guix pull’ comes with
> ‘glibc-utf8-locales’ since commit
> ba48895899a117d6ace2209c3f54411a4a989133, but the locale you’re using
> could be missing from that.)
>
> > downloading from
> > https://ci.guix.gnu.org/nar/lzip/0llx3y194278l5ksr4xh9kc64mh8nn8d-nss-certs-3.52.1
> > ...
> >  nss-certs-3.52.1  133KiB                                    186KiB/s 00:00
> > [########          ]  48.3%
> > Backtrace:
> >            3 (apply-smob/1 #<catch-closure 7f10d4c80120>)
> > In ice-9/boot-9.scm:
> >     705:2  2 (call-with-prompt _ _ #<procedure default-prompt-handle?>)
> > In ice-9/eval.scm:
> >     619:8  1 (_ #(#(#<directory (guile-user) 7f10d490e140>)))
> > In guix/ui.scm:
> >   1936:12  0 (run-guix-command _ . _)
> >
> > guix/ui.scm:1936:12: In procedure run-guix-command:
> > Throw to key `encoding-error' with args `("scm_to_stringn" "cannot convert
> > wide string to output locale" 84 #f #f)'.
> > substitution of
> > /gnu/store/0llx3y194278l5ksr4xh9kc64mh8nn8d-nss-certs-3.52.1 failed
>
> This is really puzzling: guix-daemon is always running in a valid UTF-8
> locale, as can be seen like this:
>
> --8<---------------cut here---------------start------------->8---
> $ sudo herd status guix-daemon
> Status of guix-daemon:
>   It is started.
>   Running value is 29814.
>   It is enabled.
>   Provides (guix-daemon).
>   Requires (user-processes).
>   Conflicts with ().
>   Will be respawned.
> $ sudo cat /proc/29814/environ |tr '\0' '\n'
> GUIX_LOCPATH=/gnu/store/z7a6sbvqzb5zapwpznmjkq2rsxil6i67-glibc-utf8-locales-2.31/lib/locale
> LC_ALL=en_US.utf8
> --8<---------------cut here---------------end--------------->8---

$ sudo herd status guix-daemon
Password:
Status of guix-daemon:
  It is started.
  Running value is 229.
  It is enabled.
  Provides (guix-daemon).
  Requires (user-processes).
  Conflicts with ().
  Will be respawned.
$ sudo cat /proc/229/environ | tr '\0' '\n'
GUIX_LOCPATH=/gnu/store/n79cf8bvy3k96gjk1rf18d36w40lkwlr-glibc-utf8-locales-2.29/lib/locale
LC_ALL=en_US.utf8

Shouldn't this be en_AU.utf8? Or at least en_GB.utf8?

There is an en_AU locale available:
$ ls /run/current-system/locale/2.29/en_AU.utf8/LC_MESSAGES/
SYS_LC_MESSAGES

I notice there's also 2 en_US locales:

$ /run/current-system/locale/2.29/en_US.
en_US.utf8/  en_US.UTF-8/

The locales all _appear_ to be there

$ ls /run/current-system/locale/2.29/en_*/
/run/current-system/locale/2.29/en_AU.utf8/:
LC_ADDRESS  LC_CTYPE           LC_MEASUREMENT  LC_MONETARY  LC_NUMERIC
 LC_TELEPHONE
LC_COLLATE  LC_IDENTIFICATION  LC_MESSAGES/    LC_NAME      LC_PAPER    LC_TIME

/run/current-system/locale/2.29/en_CA.utf8/:
LC_ADDRESS  LC_CTYPE           LC_MEASUREMENT  LC_MONETARY  LC_NUMERIC
 LC_TELEPHONE
LC_COLLATE  LC_IDENTIFICATION  LC_MESSAGES/    LC_NAME      LC_PAPER    LC_TIME

/run/current-system/locale/2.29/en_GB.utf8/:
LC_ADDRESS  LC_CTYPE           LC_MEASUREMENT  LC_MONETARY  LC_NUMERIC
 LC_TELEPHONE
LC_COLLATE  LC_IDENTIFICATION  LC_MESSAGES/    LC_NAME      LC_PAPER    LC_TIME

/run/current-system/locale/2.29/en_US.utf8/:
LC_ADDRESS  LC_CTYPE           LC_MEASUREMENT  LC_MONETARY  LC_NUMERIC
 LC_TELEPHONE
LC_COLLATE  LC_IDENTIFICATION  LC_MESSAGES/    LC_NAME      LC_PAPER    LC_TIME

/run/current-system/locale/2.29/en_US.UTF-8/:
LC_ADDRESS  LC_CTYPE           LC_MEASUREMENT  LC_MONETARY  LC_NUMERIC
 LC_TELEPHONE
LC_COLLATE  LC_IDENTIFICATION  LC_MESSAGES/    LC_NAME      LC_PAPER    LC_TIME



But the contents of the LC_MESSAGES directories differ.

$ ls /run/current-system/locale/2.29/en_*/**
/run/current-system/locale/2.29/en_AU.utf8/LC_ADDRESS
/run/current-system/locale/2.29/en_AU.utf8/LC_COLLATE
/run/current-system/locale/2.29/en_AU.utf8/LC_CTYPE
/run/current-system/locale/2.29/en_AU.utf8/LC_IDENTIFICATION
/run/current-system/locale/2.29/en_AU.utf8/LC_MEASUREMENT
/run/current-system/locale/2.29/en_AU.utf8/LC_MONETARY
/run/current-system/locale/2.29/en_AU.utf8/LC_NAME
/run/current-system/locale/2.29/en_AU.utf8/LC_NUMERIC
/run/current-system/locale/2.29/en_AU.utf8/LC_PAPER
/run/current-system/locale/2.29/en_AU.utf8/LC_TELEPHONE
/run/current-system/locale/2.29/en_AU.utf8/LC_TIME
/run/current-system/locale/2.29/en_CA.utf8/LC_ADDRESS
/run/current-system/locale/2.29/en_CA.utf8/LC_COLLATE
/run/current-system/locale/2.29/en_CA.utf8/LC_CTYPE
/run/current-system/locale/2.29/en_CA.utf8/LC_IDENTIFICATION
/run/current-system/locale/2.29/en_CA.utf8/LC_MEASUREMENT
/run/current-system/locale/2.29/en_CA.utf8/LC_MONETARY
/run/current-system/locale/2.29/en_CA.utf8/LC_NAME
/run/current-system/locale/2.29/en_CA.utf8/LC_NUMERIC
/run/current-system/locale/2.29/en_CA.utf8/LC_PAPER
/run/current-system/locale/2.29/en_CA.utf8/LC_TELEPHONE
/run/current-system/locale/2.29/en_CA.utf8/LC_TIME
/run/current-system/locale/2.29/en_GB.utf8/LC_ADDRESS
/run/current-system/locale/2.29/en_GB.utf8/LC_COLLATE
/run/current-system/locale/2.29/en_GB.utf8/LC_CTYPE
/run/current-system/locale/2.29/en_GB.utf8/LC_IDENTIFICATION
/run/current-system/locale/2.29/en_GB.utf8/LC_MEASUREMENT
/run/current-system/locale/2.29/en_GB.utf8/LC_MONETARY
/run/current-system/locale/2.29/en_GB.utf8/LC_NAME
/run/current-system/locale/2.29/en_GB.utf8/LC_NUMERIC
/run/current-system/locale/2.29/en_GB.utf8/LC_PAPER
/run/current-system/locale/2.29/en_GB.utf8/LC_TELEPHONE
/run/current-system/locale/2.29/en_GB.utf8/LC_TIME
/run/current-system/locale/2.29/en_US.utf8/LC_ADDRESS
/run/current-system/locale/2.29/en_US.UTF-8/LC_ADDRESS
/run/current-system/locale/2.29/en_US.utf8/LC_COLLATE
/run/current-system/locale/2.29/en_US.UTF-8/LC_COLLATE
/run/current-system/locale/2.29/en_US.utf8/LC_CTYPE
/run/current-system/locale/2.29/en_US.UTF-8/LC_CTYPE
/run/current-system/locale/2.29/en_US.utf8/LC_IDENTIFICATION
/run/current-system/locale/2.29/en_US.UTF-8/LC_IDENTIFICATION
/run/current-system/locale/2.29/en_US.utf8/LC_MEASUREMENT
/run/current-system/locale/2.29/en_US.UTF-8/LC_MEASUREMENT
/run/current-system/locale/2.29/en_US.utf8/LC_MONETARY
/run/current-system/locale/2.29/en_US.UTF-8/LC_MONETARY
/run/current-system/locale/2.29/en_US.utf8/LC_NAME
/run/current-system/locale/2.29/en_US.UTF-8/LC_NAME
/run/current-system/locale/2.29/en_US.utf8/LC_NUMERIC
/run/current-system/locale/2.29/en_US.UTF-8/LC_NUMERIC
/run/current-system/locale/2.29/en_US.utf8/LC_PAPER
/run/current-system/locale/2.29/en_US.UTF-8/LC_PAPER
/run/current-system/locale/2.29/en_US.utf8/LC_TELEPHONE
/run/current-system/locale/2.29/en_US.UTF-8/LC_TELEPHONE
/run/current-system/locale/2.29/en_US.utf8/LC_TIME
/run/current-system/locale/2.29/en_US.UTF-8/LC_TIME

/run/current-system/locale/2.29/en_AU.utf8/LC_MESSAGES:
SYS_LC_MESSAGES

/run/current-system/locale/2.29/en_CA.utf8/LC_MESSAGES:
SYS_LC_MESSAGES

/run/current-system/locale/2.29/en_GB.utf8/LC_MESSAGES:
SYS_LC_MESSAGES

/run/current-system/locale/2.29/en_US.utf8/LC_MESSAGES:
SYS_LC_MESSAGES

/run/current-system/locale/2.29/en_US.UTF-8/LC_MESSAGES:
SYS_LC_MESSAGES

Is this correct?
At first glance (with no knowledge of how the locales work) I would
assume that en_AU and en_CA overlay onto en_GB.
But even en_GB is effectively empty, which would contradict that assumption.


>
> However, I just realized that ‘guix substitute’ switches to the client’s
> locale:
>
> --8<---------------cut here---------------start------------->8---
>   ;; Attempt to install the client's locale, mostly so that messages are
>   ;; suitably translated.
>   (match (or (find-daemon-option "untrusted-locale")
>              (find-daemon-option "locale"))
>     (#f     #f)
>     (locale (false-if-exception (setlocale LC_ALL locale))))
> --8<---------------cut here---------------end--------------->8---
>
> Thus, if the client is running in a non-UTF-8 locale, we can end up with
> the error you report.
>
> Thanks,
> Ludo’.




  reply	other threads:[~2020-08-29  3:36 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-25 10:43 bug#43039: Vanilla GUIX 1.1.0 reconfigure fails on nss-certs Adam Griffiths
2020-08-27  1:21 ` conjaroy
2020-08-28 14:05 ` Ludovic Courtès
2020-08-29  3:10   ` Adam Griffiths [this message]
2020-09-02 15:21     ` Ludovic Courtès
     [not found] ` <handler.43039.D43039.159906009821340.notifdone@debbugs.gnu.org>
2020-09-02 23:57   ` bug#43039: closed (Re: bug#43039: Vanilla GUIX 1.1.0 reconfigure fails on nss-certs) Adam Griffiths

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAFgA=J6bETsaRYBNX9_GRqfGuRPeDezqScq0VZdYY3aAdz6MPA@mail.gmail.com' \
    --to=adam.lw.griffiths@gmail.com \
    --cc=43039@debbugs.gnu.org \
    --cc=ludo@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).