Snap: Regional settings not listed/respected in Ubuntu 22
Categories
(Thunderbird :: OS Integration, defect)
Tracking
(Not tracked)
People
(Reporter: rb, Unassigned)
Details
User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:105.0) Gecko/20100101 Firefox/105.0
Steps to reproduce:
- Install Ubuntu 22.04.1 desktop.
- Install Thunderbird snap (gives version 102.3.3-1)
- In system settings -> Region & Language, set Language to English (United States) AND set Formats (used for dates, times, numbers) to English (United Kingdom)
Actual results:
Two related problems:
- Thunderbird dates displayed in US format (MM/DD/YYYY), ignoring the system setting for date format.
- Thunderbird settings, under Date and Time Formatting, do not offer English (United Kingdom), contradicting documentation at https://support.mozilla.org/en-US/kb/customize-date-time-formats-thunderbird which says that whatever is in the system settings should be offered.
Expected results:
- Thunderbird respects the system setting for regional date format.
- Thunderbird offers installed regional formats in its own settings.
| Reporter | ||
Comment 1•3 years ago
|
||
To clarify, the setup described above produces the following in the Thunderbird General settings:
Date and Time Formatting
(x) Application locale: English (United Kingdom)
( ) Regional settings locale: English (United States, posix)
You can select English (United Kingdom) and restart Thunderbird, but dates are still displayed in US format (MM/DD/YYYY), so this has no effect.
Experimentally, I installed the Japanese language using the system settings, and set my formats to Japanese there. Restarting Thunderbird, it did not offer Japanese in its settings (which is also a subject of this report) so I was not able to test whether selecting it has an effect.
Comment 2•3 years ago
|
||
This should work just fine with a build from thunderbird.net. Likely an issue with the snap, but that is not maintained by the Thunderbird team.
| Reporter | ||
Comment 3•3 years ago
|
||
(In reply to Magnus Melin [:mkmelin] from comment #2)
This should work just fine with a build from thunderbird.net. Likely an issue with the snap, but that is not maintained by the Thunderbird team.
OK, to check this I downloaded Thunderbird fresh from thunderbird.net https://download.mozilla.org/?product=thunderbird-102.4.0-SSL&os=linux64&lang=en-US and ran it on a completely fresh profile.
Thunderbird still ignored the regional settings for date and time.
In this case I had the system language set to en_GB.UTF-8 but LC_DATE set to en_DK.UTF-8. I should be seeing ISO dates in the format YYYY-MM-DD, but Thunderbird is showing them in DD/MM/YYYY format, even though my settings say
Date and Time Formatting
( ) Application locale: English (United Kingdom)
(x) Regional settings locale: English (Denmark)
So I do not believe this is an issue with the snap packaging.
| Reporter | ||
Comment 4•3 years ago
|
||
(In reply to Richard Brooksby from comment #3)
In this case I had the system language set to en_GB.UTF-8 but LC_DATE set to en_DK.UTF-8.
Sorry that should say LC_TIME. It was set by the System Settings -> Language and Region, which in this case show:
Language: English (United Kingdom)
Formats: Denmark (English)
which produces an environment like this
$ locale
LANG=en_GB.UTF-8
LANGUAGE=en_GB:en
LC_CTYPE="en_GB.UTF-8"
LC_NUMERIC=en_DK.UTF-8
LC_TIME=en_DK.UTF-8
LC_COLLATE="en_GB.UTF-8"
LC_MONETARY=en_DK.UTF-8
LC_MESSAGES="en_GB.UTF-8"
LC_PAPER=en_DK.UTF-8
LC_NAME=en_DK.UTF-8
LC_ADDRESS=en_DK.UTF-8
LC_TELEPHONE=en_DK.UTF-8
LC_MEASUREMENT=en_DK.UTF-8
LC_IDENTIFICATION=en_DK.UTF-8
LC_ALL=
Comment 5•3 years ago
|
||
In the Error Console, type in Services.locale.regionalPrefsLocales; and see what that is.
Is the danish locale actually set up on the system? (Not just the variable.)
| Reporter | ||
Comment 6•3 years ago
|
||
(In reply to Magnus Melin [:mkmelin] from comment #5)
In the Error Console, type in
Services.locale.regionalPrefsLocales;and see what that is.
Array [ "en-DK" ]
Is the danish locale actually set up on the system? (Not just the variable.)
It was installed by the System Settings. But just to make sure, I ranlocale-genand bothen_GB.UTF-8anden_DK.UTF-8were re-generated. But this didn't affect the behaviour.
| Reporter | ||
Comment 7•3 years ago
|
||
To contrast, running LC_TIME=en_GB.UTF-8 shotwell causes Shotwell to show import folders with British times and dates. But LC_TIME=en_DK.UTF-8 shotwell causes them to show up with ISO times and dates. But the same things with Thunderbird (Snap or downloaded) do not. Just to make things complicated, LC_TIME=ja_JP.UTF-8 thunderbird does cause Thunderbird to change the date format.
It seems that some combinations don't work as they should, but it's not consistent.
Please let me know if there's anything I can do to investigate further.
Comment 8•3 years ago
|
||
Hmm, are you sure it's MM/DD/YYYY? en_DK is specified in CLDR as dd/MM/y.
See bug 1426907
| Reporter | ||
Comment 9•3 years ago
|
||
I will read the thread in detail, but what I'm guessing now is that Thunderbird does not use the system generated locales, but has its own definitions. That's why it is inconsistent with e.g. Shotwell.
On Ubuntu 22, /usr/share/i18n/locales/en_DK says:
title "English locale for Denmark"
source "Danish Standards Association"
...
revision "1.0"
date "2000-06-29"
...
% date formats following ISO 8601-1988
d_t_fmt "%Y-%m-%dT%T %Z"
date_fmt "%Y-%m-%dT%T %Z"
d_fmt "%Y-%m-%d"
t_fmt "%T"
am_pm "";""
t_fmt_ampm ""
week 7;19971130;4
first_weekday 2
...
% en_DK is used outside Denmark, as some sort of generic continental
% European English locale.
...
Also:
$ python3 -c "import datetime; import locale; locale.setlocale(locale.LC_TIME, 'en_DK.utf8'); print(datetime.datetime(2022, 10, 25, 6, 12, 56, 866955).strftime('%x'))"
2022-10-25
I will investigate further in the next few days. Thank you for the pointers.
Comment 10•3 years ago
|
||
Ubuntu doesn't use CLDR for that.
Description
•