[Bug 2035044] Re: gnome-language-selector -> Regional Formats: Please indicate if it is overriden by LC_ALL

Gunnar Hjalmarsson 2035044 at bugs.launchpad.net
Tue Sep 12 12:04:00 UTC 2023


> $ cat /etc/default/locale
> # File generated by update-locale
> LANG="en_US.UTF-8"
> LC_NUMERIC="en_CA.UTF-8"
> LC_TIME="en_CA.UTF-8"
> LC_MONETARY="en_CA.UTF-8"
> LC_PAPER="en_CA.UTF-8"
> LC_IDENTIFICATION="en_CA.UTF-8"
> LC_NAME="en_CA.UTF-8"
> LC_ADDRESS="en_CA.UTF-8"
> LC_TELEPHONE="en_CA.UTF-8"
> LC_MEASUREMENT="en_CA.UTF-8"
> 
> $ locale
> LANG=en_US.UTF-8
> LANGUAGE=en_US
> LC_CTYPE="en_US.UTF-8"
> LC_NUMERIC=en_CA.UTF-8
> LC_TIME=en_CA.UTF-8
> LC_COLLATE="en_US.UTF-8"
> LC_MONETARY=en_CA.UTF-8
> LC_MESSAGES="en_US.UTF-8"
> LC_PAPER=en_CA.UTF-8
> LC_NAME=en_CA.UTF-8
> LC_ADDRESS=en_CA.UTF-8
> LC_TELEPHONE=en_CA.UTF-8
> LC_MEASUREMENT=en_CA.UTF-8
> LC_IDENTIFICATION=en_CA.UTF-8
> LC_ALL=
> 
> $ locale | grep en_US | grep LC_
> LC_CTYPE="en_US.UTF-8"
> LC_COLLATE="en_US.UTF-8"
> LC_MESSAGES="en_US.UTF-8"
> 
> The latter variables are not set to "en_CA.UTF-8"

That's true, and it's intended behavior. The idea is to distinguish
between language and regional formats, and the latter variables are
considered to be part of the language option.

> "Setting LC_ALL that way persistently on a desktop is a misconfiguration"?
> 
> Is it? 

Yes it is. If you want the same locale for every locale category, just
make sure that you select the same locale for both language and regional
formats.

LC_ALL is typically used by coders. It's not suitable as an environment
variable on a desktop, since it makes any UI for this purpose useless.

If you want to make an exception for a particular locale category, e.g.
LC_CTYPE or LC_TIME, then set that category separately. But leave LC_ALL
unset.

> How does gnome-language-selector reload ~/.pam_environment ?

It doesn't. PAM loads ~/.pam_environment at login.

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to language-selector in Ubuntu.
https://bugs.launchpad.net/bugs/2035044

Title:
  gnome-language-selector -> Regional Formats: Please indicate if it is
  overriden by LC_ALL

Status in language-selector package in Ubuntu:
  Opinion

Bug description:
  * Open gnome-language-selector, and click on the Regional Formats tab.
  * Change the value in the `Display numbers, dates and currency amounts in the usual format for:` drop-down list, say `English (Canada)`
  * Close the gnome-language-selector window.
  * Run this in a terminal: `your_locale="en_US"; sudo update-locale LANG="$your_locale".UTF-8 LANGUAGE="$your_locale" LC_ALL="$your_locale".UTF-8`
  * Log out and in from the desktop environment
  * Again, open gnome-language-selector, and click on the Regional Formats tab. As you can see, it appears like `English (Canada)` even if it is overridden by LC_ALL ("English (United States)")

  ProblemType: Bug
  DistroRelease: Ubuntu 23.04
  Package: language-selector-gnome 0.221
  ProcVersionSignature: Ubuntu 6.2.0-20.20-generic 6.2.6
  Uname: Linux 6.2.0-20-generic x86_64
  ApportVersion: 2.26.1-0ubuntu2
  Architecture: amd64
  CasperMD5CheckResult: unknown
  CurrentDesktop: ubuntu:GNOME
  Date: Mon Sep 11 01:42:32 2023
  InstallationDate: Installed on 2023-04-23 (140 days ago)
  InstallationMedia: Ubuntu 23.04 "Lunar Lobster" - Release amd64 (20230418)
  PackageArchitecture: all
  ProcEnviron:
   LANG=en_US.UTF-8
   PATH=(custom, no user)
   SHELL=/bin/bash
   TERM=xterm-256color
   XDG_RUNTIME_DIR=<set>
  SourcePackage: language-selector
  UpgradeStatus: No upgrade log present (probably fresh install)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/language-selector/+bug/2035044/+subscriptions




More information about the foundations-bugs mailing list