unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
* bug#37897: Bug: Resetting locale settings
@ 2019-10-23 22:49 o.rojon
  2019-10-23 23:27 ` Tobias Geerinckx-Rice via Bug reports for GNU Guix
  2019-10-25 20:44 ` Ludovic Courtès
  0 siblings, 2 replies; 7+ messages in thread
From: o.rojon @ 2019-10-23 22:49 UTC (permalink / raw)
  To: 37897

Hello guix,

I believe that a locale-related bug has slipped in somewhere in the last 
two-three weeks. During installation and in my configuration file, I 
have specified de_DE specified as locale, which should translate to a 
german keyboard layout. But since said two-three weeks, I startup with 
what I believe is the US layout (qwerty) - and before this occurred, I 
was once even unable to login because my keyboard layout has been 
changed to something so obscure it didnt even seem to know basic 
characters like the exclamation mark, while there was a number of 
characters that could not be displayed (probably non-utf characters I 
suppose).

In the latter case, I was able to login via 'loadkeys 
/run/current-system/profile/share/keymaps/i386/qwertz/de-latin1' in TTY 
(where I went with C-M-F2 or F3, nvm); but now, I am unable to set the 
keymap via loadkeys. When I dont use sudo, I receive the message 'data 
descriptor referring to console couldnt be found' (translated from 
german "Dateideskriptor, der auf die Konsole verweist, konnte nicht 
gefunden werden."); if I do use sudo, I dont get an error, but the 
keyboard layout doesnt change.

I really dont know what I could've contributed to produce such a 
situation. The only thing I noticed is that it KIND OF coincides with me 
installing glibc to make guile stop nagging that "locale couldnt be 
found" (or something like that).

Obviously, help would be appreciated :)

Greetings!

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

* bug#37897: Bug: Resetting locale settings
  2019-10-23 22:49 bug#37897: Bug: Resetting locale settings o.rojon
@ 2019-10-23 23:27 ` Tobias Geerinckx-Rice via Bug reports for GNU Guix
  2019-10-25 20:44 ` Ludovic Courtès
  1 sibling, 0 replies; 7+ messages in thread
From: Tobias Geerinckx-Rice via Bug reports for GNU Guix @ 2019-10-23 23:27 UTC (permalink / raw)
  To: 37897

[-- Attachment #1: Type: text/plain, Size: 1011 bytes --]

Hullo again,

I can't help you with your exact problem, but

o.rojon@posteo.net 写道:
> In the latter case, I was able to login via 'loadkeys
> /run/current-system/profile/share/keymaps/i386/qwertz/de-latin1' 
> in
> TTY (where I went with C-M-F2 or F3, nvm); but now, I am unable 
> to set
> the keymap via loadkeys. When I dont use sudo, I receive the 
> message
> 'data descriptor referring to console couldnt be found' 
> (translated
> from german "Dateideskriptor, der auf die Konsole verweist, 
> konnte
> nicht gefunden werden."); if I do use sudo, I dont get an error, 
> but
> the keyboard layout doesnt change.

I ran ‘sudo loadkeys de-latin1’ on VT 2, where my ‘y’ key now does 
the bad thing.  So it works here.

This mix of loadkeys and setxkbmap confuses me, though: are you 
trying to log in on a VT (the Linux console), or X?

‘loadkeys’ only handles the former, ‘setxkbmap’ only the latter. 
They are entirely separate.

Kind regards,

T G-R

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 832 bytes --]

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

* bug#37897: Bug: Resetting locale settings
  2019-10-23 22:49 bug#37897: Bug: Resetting locale settings o.rojon
  2019-10-23 23:27 ` Tobias Geerinckx-Rice via Bug reports for GNU Guix
@ 2019-10-25 20:44 ` Ludovic Courtès
  2019-10-26 21:26   ` o.rojon
  1 sibling, 1 reply; 7+ messages in thread
From: Ludovic Courtès @ 2019-10-25 20:44 UTC (permalink / raw)
  To: o.rojon; +Cc: 37897

Hello,

o.rojon@posteo.net skribis:

> I believe that a locale-related bug has slipped in somewhere in the
> last two-three weeks. During installation and in my configuration
> file, I have specified de_DE specified as locale, which should
> translate to a german keyboard layout. But since said two-three weeks,
> I startup with what I believe is the US layout (qwerty) - and before
> this occurred, I was once even unable to login because my keyboard
> layout has been changed to something so obscure it didnt even seem to
> know basic characters like the exclamation mark, while there was a
> number of characters that could not be displayed (probably non-utf
> characters I suppose).

Could you be more specific about the context in which you get an
incorrect layout (console, Xorg, Wayland, GNOME, etc.)?

Note that locale settings and keyboard layout settings are entirely
separate—choosing the “de_DE” locale gives you programs that speak
German, but it does not give you a “qwertz” layout.  See:

  https://guix.gnu.org/manual/devel/en/html_node/Keyboard-Layout.html
  https://guix.gnu.org/manual/devel/en/html_node/Locales.html

HTH,
Ludo’.

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

* bug#37897: Bug: Resetting locale settings
  2019-10-25 20:44 ` Ludovic Courtès
@ 2019-10-26 21:26   ` o.rojon
  2019-11-13 13:48     ` Ludovic Courtès
  0 siblings, 1 reply; 7+ messages in thread
From: o.rojon @ 2019-10-26 21:26 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: 37897

Hello Ludo,

maybe I have been a bit unprecise in my wording, Im rather new to that 
level of configurability.

So I was talking about the keyboard layout all along. Not only was my 
locale set to "de_DE.utf8", but my keyboard configuration is set to 
"de-latin1-nodeadkeys". Interestingly, the keyboard layout is different 
in xorg and xfce than it is in the console (the one I reach via C-M-Fx, 
not the terminal emulator). In the console, I have the qwertz keyboard 
layout.

Also find the part of my current configuration file (sitting at 
/etc/config.scm) which specifies both locale and keyboard layout:
(operating-system
   (locale "de_DE.utf8")
   (timezone "Europe/Berlin")
   (keyboard-layout (keyboard-layout "de" "latin1-nodeadkeys"))
   (bootloader
     (bootloader-configuration
       (bootloader grub-bootloader)
       (target "/dev/sdb")
       (keyboard-layout keyboard-layout)))

I was surprised by the behaviour described in my bug report because I 
saw that the value for "keyboard-layout", which is set very early in the 
operating-system declaration, is simply copied over in later parts of 
the configuration file.

If you need anything else, please specify. Again, Im rather new to these 
things, so sorry for technical inspecificity.

Greetings!

On 25.10.2019 22:44, Ludovic Courtès wrote:
> Hello,
> 
> o.rojon@posteo.net skribis:
> 
>> I believe that a locale-related bug has slipped in somewhere in the
>> last two-three weeks. During installation and in my configuration
>> file, I have specified de_DE specified as locale, which should
>> translate to a german keyboard layout. But since said two-three weeks,
>> I startup with what I believe is the US layout (qwerty) - and before
>> this occurred, I was once even unable to login because my keyboard
>> layout has been changed to something so obscure it didnt even seem to
>> know basic characters like the exclamation mark, while there was a
>> number of characters that could not be displayed (probably non-utf
>> characters I suppose).
> 
> Could you be more specific about the context in which you get an
> incorrect layout (console, Xorg, Wayland, GNOME, etc.)?
> 
> Note that locale settings and keyboard layout settings are entirely
> separate—choosing the “de_DE” locale gives you programs that speak
> German, but it does not give you a “qwertz” layout.  See:
> 
>   https://guix.gnu.org/manual/devel/en/html_node/Keyboard-Layout.html
>   https://guix.gnu.org/manual/devel/en/html_node/Locales.html
> 
> HTH,
> Ludo’.

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

* bug#37897: Bug: Resetting locale settings
  2019-10-26 21:26   ` o.rojon
@ 2019-11-13 13:48     ` Ludovic Courtès
  2019-11-14 12:23       ` o.rojon
  0 siblings, 1 reply; 7+ messages in thread
From: Ludovic Courtès @ 2019-11-13 13:48 UTC (permalink / raw)
  To: o.rojon; +Cc: 37897

Hi,

o.rojon@posteo.net skribis:

> So I was talking about the keyboard layout all along. Not only was my
> locale set to "de_DE.utf8", but my keyboard configuration is set to
> "de-latin1-nodeadkeys". Interestingly, the keyboard layout is
> different in xorg and xfce than it is in the console (the one I reach
> via C-M-Fx, not the terminal emulator). In the console, I have the
> qwertz keyboard layout.
>
> Also find the part of my current configuration file (sitting at
> /etc/config.scm) which specifies both locale and keyboard layout:
> (operating-system
>   (locale "de_DE.utf8")
>   (timezone "Europe/Berlin")
>   (keyboard-layout (keyboard-layout "de" "latin1-nodeadkeys"))
>   (bootloader
>     (bootloader-configuration
>       (bootloader grub-bootloader)
>       (target "/dev/sdb")
>       (keyboard-layout keyboard-layout)))

Could you post your complete config file?

The snippet above defines the keyboard layout for the console and for
GRUB, but it does not define the keyboard layout for Xorg/Xfce.  For
that you need an extra bit with ‘set-xorg-configuration’ as noted at
<https://guix.gnu.org/manual/devel/en/html_node/Keyboard-Layout.html>.

Thanks in advance,
Ludo’.

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

* bug#37897: Bug: Resetting locale settings
  2019-11-13 13:48     ` Ludovic Courtès
@ 2019-11-14 12:23       ` o.rojon
  2019-11-14 21:51         ` Ludovic Courtès
  0 siblings, 1 reply; 7+ messages in thread
From: o.rojon @ 2019-11-14 12:23 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: 37897

Hello ludo, hey guys,

here you go. I took the liberty to anonymize and to skip the package 
modules and packages sections.

I realised that when I dont specify WHICH KIND of german keyboard layout 
I have, the problem does not occur. That is, if I use the 
(keyboard-layout (keyboard-layout "de")), I dont have any problems.

Thus I suppose that there might be something wrong with the spelling of 
the specification (compare both commented-out attempts at 
specification). Strictly speaking, then, it may not be a bug. But if it 
is not a bug, I dont know how specify the specification, since in the 
manual the specification consists of only one word (e.g. "fr" "bepo"), 
and under /run/current-system/profile/share/keymaps/i386/qwertz/, said 
keymap is listed as "de-latin1-nodeadkeys".

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

(operating-system
   (locale "de_DE.utf8")
   (timezone "Europe/Berlin")
;;  (keyboard-layout (keyboard-layout "de" "latin1-nodeadkeys"))
;;  (keyboard-layout (keyboard-layout "de" "latin1 nodeadkeys"))
   (keyboard-layout (keyboard-layout "de"))
   (bootloader
     (bootloader-configuration
       (bootloader grub-bootloader)
       (target "/dev/sdb")
       (keyboard-layout keyboard-layout)))
   (swap-devices (list "/dev/sdb3"))
   (file-systems
     (cons* (file-system
              (mount-point "/home")
              (device
                (uuid "8ee0b983-53f0-4e18-852f-8cd4424a6c6f"
                      'btrfs))
              (type "btrfs"))
            (file-system
              (mount-point "/")
              (device
                (uuid "cb425a5f-bd91-45d3-92e1-3b983450ee21"
                      'ext4))
              (type "ext4"))
            %base-file-systems))
   (host-name "guixter")
   (users (cons* (user-account
                   (name "user")
                   (comment "")
                   (group "users")
                   (home-directory "/home/user")
                   (supplementary-groups
                     '("wheel" "netdev" "audio" "video")))
                 %base-user-accounts))
   (packages
     (append
      (list ...)
       %base-packages))
   (services
     (append
       (list (service xfce-desktop-service-type)
             (set-xorg-configuration
               (xorg-configuration
                 (keyboard-layout keyboard-layout))))
       %desktop-services)))

Greetings,
Olivier

On 13.11.2019 14:48, Ludovic Courtès wrote:
> Hi,
> 
> o.rojon@posteo.net skribis:
> 
>> So I was talking about the keyboard layout all along. Not only was my
>> locale set to "de_DE.utf8", but my keyboard configuration is set to
>> "de-latin1-nodeadkeys". Interestingly, the keyboard layout is
>> different in xorg and xfce than it is in the console (the one I reach
>> via C-M-Fx, not the terminal emulator). In the console, I have the
>> qwertz keyboard layout.
>> 
>> Also find the part of my current configuration file (sitting at
>> /etc/config.scm) which specifies both locale and keyboard layout:
>> (operating-system
>>   (locale "de_DE.utf8")
>>   (timezone "Europe/Berlin")
>>   (keyboard-layout (keyboard-layout "de" "latin1-nodeadkeys"))
>>   (bootloader
>>     (bootloader-configuration
>>       (bootloader grub-bootloader)
>>       (target "/dev/sdb")
>>       (keyboard-layout keyboard-layout)))
> 
> Could you post your complete config file?
> 
> The snippet above defines the keyboard layout for the console and for
> GRUB, but it does not define the keyboard layout for Xorg/Xfce.  For
> that you need an extra bit with ‘set-xorg-configuration’ as noted at
> <>.
> 
> Thanks in advance,
> Ludo’.

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

* bug#37897: Bug: Resetting locale settings
  2019-11-14 12:23       ` o.rojon
@ 2019-11-14 21:51         ` Ludovic Courtès
  0 siblings, 0 replies; 7+ messages in thread
From: Ludovic Courtès @ 2019-11-14 21:51 UTC (permalink / raw)
  To: o.rojon; +Cc: 37897-done

Hi,

o.rojon@posteo.net skribis:

> Hello ludo, hey guys,

Guys and gals.  :-)

> I realised that when I dont specify WHICH KIND of german keyboard
> layout I have, the problem does not occur. That is, if I use the
> (keyboard-layout (keyboard-layout "de")), I dont have any problems.

Oh I see, the “variant” part is indeed the problem.

> ;;  (keyboard-layout (keyboard-layout "de" "latin1-nodeadkeys"))

If we build verbosely, we see:

--8<---------------cut here---------------start------------->8---
building /gnu/store/r3pibry4qsyfs090fcxglvfr52vfq3cx-console-keymap.de.drv...
WARNING: Can not find "latin1nodeadkeys" in "de".
WARNING: Unknown X keysym "dead_belowmacron"
WARNING: Unknown X keysym "dead_belowmacron"
WARNING: Unknown X keysym "dead_belowmacron"
WARNING: Unknown X keysym "dead_belowmacron"
successfully built /gnu/store/r3pibry4qsyfs090fcxglvfr52vfq3cx-console-keymap.de.drv
--8<---------------cut here---------------end--------------->8---

IOW, under the hood, the ‘ckbcomp’ program, which converts from XKB to
console layout data, wans us that it doesn’t know anything about
“latin1nodeadkeys” and then goes on to ignore the issue.  I’m not sure
how to avoid that.

As noted in
<https://guix.gnu.org/manual/devel/en/html_node/Keyboard-Layout.html>,
the list of supported keyboard variants is to be found in the
‘xkeyboard-config’ package:

  less $(guix build xkeyboard-config)/share/X11/xkb/rules/base.xml

Though I have to admit that it’s not user-friendly.

Anyway, I’m closing the bug for now, but please to reopen it if you
think further discussion is needed (or email help-guix@gnu.org).

Thank you!

Ludo’.

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

end of thread, other threads:[~2019-11-14 21:52 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-23 22:49 bug#37897: Bug: Resetting locale settings o.rojon
2019-10-23 23:27 ` Tobias Geerinckx-Rice via Bug reports for GNU Guix
2019-10-25 20:44 ` Ludovic Courtès
2019-10-26 21:26   ` o.rojon
2019-11-13 13:48     ` Ludovic Courtès
2019-11-14 12:23       ` o.rojon
2019-11-14 21:51         ` Ludovic Courtès

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