snap-based programs complain about locale
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
snapd (Ubuntu) |
Incomplete
|
Undecided
|
Unassigned |
Bug Description
This is a followup to Launchpad Bug#1959845, as I was asked to file a separate bug report for the locale issue.
I am running Ubuntu 22.04.1 LTS on x86-64 with current patches. I am using snapd 1.60-0ubuntu1.
When I run the shell command "chromium --version" and attempt to debug the resulting situation a bit, I see the following. As you can see, I get a bogus diagnostic about the locale. My locale is fine, although evidently snap packages can't use it.
$ chromium --version
/bin/bash: warning: setlocale: LC_ALL: cannot change locale (en_US.utf8)
Chromium 103.0.5060.134 snap
$ LC_ALL=C chromium --version
Chromium 103.0.5060.134 snap
$ echo $SHELL
/bin/bash
$ env | grep -E '^LC_|^LANG='
LANG=C
LC_ALL=en_US.utf8
$ locale
LANG=C
LANGUAGE=
LC_CTYPE=
LC_NUMERIC=
LC_TIME=
LC_COLLATE=
LC_MONETARY=
LC_MESSAGES=
LC_PAPER=
LC_NAME=
LC_ADDRESS=
LC_TELEPHONE=
LC_MEASUREMENT=
LC_IDENTIFICATI
LC_ALL=en_US.utf8
Hi Paul, and thanks for opening this.
Generally one should not use the LC_ALL variable, but the other LC_* variables instead. If you are setting LC_ALL in your .bashrc, you could try removing it and see if things continue to work.
If you have a need to use LC_ALL, then the information I found online suggests adding the variable to /etc/environment. Can you see if that helps?