• Firefox in trixie: UK date and US time

    From Max Nikulin@3:633/10 to All on Tuesday, January 06, 2026 05:30:02
    Hi,

    Some aspects of locales and timestamp formatting have been discussed
    recently. After upgrade to Debian 13 trixie I faced Firefox behavior
    rather surprising for me.

    In UI elements I have UK dd/mm/YYYY (not mm/dd/YYYY, expected however)
    date and 12 hours am/pm US time format (that I prefer to avoid). My
    impression is that LANGUAGE environment vairable has higher priority
    than LANG and LC_TIME namely for time (that is unexpected), but not for
    date. Usually I report Firefox bugs to the upstream bug tracker, but due
    to bookworm vs. trixie difference this time I suspect a Debian-specific
    issue. Can anybody confirm discrepancy?

    When firefox is not running (or use another profile)

    LANG=en_GB.UTF-8 LANGUAGE=en_US:en firefox-esr

    Open history [Ctrl+Shift+H] and enable the most recent visit column.
    What are date format and time format?

    I admit, my setup is a bit peculiar and not really consistent, but so
    far I was happy with it. I am running stripped version of plasma desktop
    and some recommended packages are missed. I am interested if the issue
    is reproducible for other DEs. I would not be surprised if it is related
    to some new D-Bus service or a library.

    I do not like inconsistency between date and time formatting. Perhaps
    the issue may be reproduced with other locales as well. Check that
    specified locales are present in output of

    locale -a

    otherwise enable them using "dpkg-reconfigure locales" or by editing of /etc/locale-gen with following locale-gen. Notice that LANGUAGE should
    contain list of languages, not locales, so do not add ".UTF-8" there.

    My experience is that locale packages like firefox-esr-l10n-en-gb are
    not important.

    Notice that web pages are another story than browser UI. You may test a
    HTML file like

    <!DOCTYPE html>
    <input type="datetime-local" value="2026-01-06T17:12">

    but it is more complicated and result may be affected by e.g. navigator.languages and intl.regional_prefs.use_os_locales.

    My native language is not English, but to have messages and menu entries
    that can be directly put into search queries at first I set
    LANG=en_US.UTF-8. Later I realized that US datetime format is
    inconvenient for me and I changed it to LANG=en_GB.UTF-8. I have not
    update LANGUAGE, so I have some sort of inconsistency. Perhaps I should
    set to en_GB.UTF-8 just LC_TIME, but in trixie it is partially
    disregarded by Fiurefox.

    I will be grateful if somebody confirms that inconsistent time vs. date formatting with disregarding of LC_TIME and LANG in presence of LANGUAGE
    may be reproduced in trixie, but not in bookworm.

    --- PyGate Linux v1.5.2
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From didier gaumet@3:633/10 to All on Tuesday, January 06, 2026 09:10:01

    Hello Max,

    I don't know KDE/Plasma well, but similarly to other DE, I think it
    benefits from being setup from it own tools (KDE System Config or
    possibly something similar to dconf for Gnome).
    So trying to fix your problem at low level (LC* variables in generic
    config files) might not be the most efficient way to solve your
    KDE/Plasma problem.

    In Trixie 13 KDE/Plasma has been update of a major version (5->6) from Bookworm 12. Some issues have been documented (menus), potential issues
    like yours may appear, I suppose. Hence the suggested use of KDE System Settings (even if the values are those you expect, try to change them to something different and then back to the wanted values, to force
    KDE/Plasma to acknowledge your setup)

    --- PyGate Linux v1.5.2
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Davidson@3:633/10 to All on Wednesday, January 07, 2026 20:20:01
    On Tue, 6 Jan 2026, Max Nikulin wrote:

    Hi,

    Good time of the day to you.


    Some aspects of locales and timestamp formatting have been discussed recently.

    I have not been around here lately, and did not see that discussion.

    After upgrade to Debian 13 trixie I faced Firefox behavior rather
    surprising for me.

    In UI elements I have UK dd/mm/YYYY (not mm/dd/YYYY, expected however) date and 12 hours am/pm US time format (that I prefer to avoid). My impression is that LANGUAGE environment vairable has higher priority than LANG and LC_TIME namely for time (that is unexpected), but not for date. Usually I report Firefox bugs to the upstream bug tracker, but due to bookworm vs. trixie difference this time I suspect a Debian-specific issue. Can anybody confirm discrepancy?

    I try to do this below.

    When firefox is not running (or use another profile)

    LANG=en_GB.UTF-8 LANGUAGE=en_US:en firefox-esr

    Open history [Ctrl+Shift+H] and enable the most recent visit column. What are
    date format and time format?
    [rest snipped]

    I'm running bullseye (which is currently oldoldstable). I have not yet
    upgraded to bookworm.

    Yesterday I installed firefox-esr, and used it to visit a couple
    websites.

    Today I ran the test described in your OP.

    Preliminaries: I have no DE. I run startx in a virtual terminal, and
    my ~/.xsession launches ratpoison, which is a window manager.

    carroll@funafuti:0 ~$ cat .xsession
    #!/bin/sh
    xsetroot -fg black -bg gray20 -mod 16 16
    exec ratpoison -f ${HOME}/.ratpoisonrc

    Then, from an xterm:

    carroll@funafuti:0 ~$ cat /etc/default/locale
    # File generated by update-locale
    LANG=en_US.UTF-8
    carroll@funafuti:0 ~$ locale
    LANG=en_US.UTF-8
    LANGUAGE=
    LC_CTYPE="en_US.UTF-8"
    LC_NUMERIC="en_US.UTF-8"
    LC_TIME="en_US.UTF-8"
    LC_COLLATE="en_US.UTF-8"
    LC_MONETARY="en_US.UTF-8"
    LC_MESSAGES="en_US.UTF-8"
    LC_PAPER="en_US.UTF-8"
    LC_NAME="en_US.UTF-8"
    LC_ADDRESS="en_US.UTF-8"
    LC_TELEPHONE="en_US.UTF-8"
    LC_MEASUREMENT="en_US.UTF-8"
    LC_IDENTIFICATION="en_US.UTF-8"
    LC_ALL=

    carroll@funafuti:0 ~$ locale -a | grep en_
    en_GB.utf8
    en_US.utf8

    carroll@funafuti:0 ~$ LANG=en_GB.utf8 LANGUAGE=en_US:en firefox-esr ./html/home.html
    [GFX1-]: RenderCompositorSWGL failed mapping default framebuffer, no dt
    [Parent 1067, IPC I/O Parent] WARNING: process 1112 exited on signal 9: file ./ipc/chromium/src/chrome/common/process_watcher_posix_sigchld.cc:134
    [GFX1-]: RenderCompositorSWGL failed mapping default framebuffer, no dt
    carroll@funafuti:0 ~$ LANG=en_US.utf8 LANGUAGE=en_US:en firefox-esr ./html/home.html
    [GFX1-]: RenderCompositorSWGL failed mapping default framebuffer, no dt
    [GFX1-]: RenderCompositorSWGL failed mapping default framebuffer, no dt
    carroll@funafuti:0 ~$

    During both of the above firefox sessions I opened a history window
    (using the keystroke shortcut you kindly provided).

    LANGUAGE was set to en_US:en on the command line in both sessions.

    This is what I see when LANG=en_GB.utf8

    Location Most Recent Visit
    ======== =================
    ... ...
    https://en.wikipedia.org/wiki/Poop 06/01/2026, 13:14

    And this is what I see when LANG=en_US.utf8

    Location Most Recent Visit
    ======== =================
    ... ...
    https://en.wikipedia.org/wiki/Poop 1/06/2026, 13:14

    As you can see, apparently I have a 24-hour clock in either case.

    Miscellaneous considerations (ie, I throw noodles at the wall):

    Noodle 1: Ratpoison, my window manager, has a time command, which
    AFAICT invariably displays date/time in 24-hour format (and in
    English)

    Noodle 2: It is unclear to me what the semantics are, of the
    preferences in the file below, but here is part of the content of my
    own. Conceivably relevant for you.

    carroll@funafuti:0 ~$ ls -lAp /etc/firefox-esr/
    total 4
    -rw-r--r-- 1 root root 1079 Dec 10 03:11 firefox-esr.js
    carroll@funafuti:0 ~$ sed '/locale\./ q' /etc/firefox-esr/firefox-esr.js
    // This is the Debian specific preferences file for Firefox ESR
    // You can make any change in here, it is the purpose of this file.
    // You can, with this file and all files present in the
    // /etc/firefox-esr directory, override any preference you can see in
    // about:config.
    //
    // Note that pref("name", value, locked) is allowed in these
    // preferences files if you don't want users to be able to override
    // some preferences.

    pref("extensions.update.enabled", true);

    // Use LANG environment variable to choose locale
    pref("intl.locale.requested", "");
    carroll@funafuti:0 ~$

    (I tried to attach my full /etc/firefox-esr/firefox-esr.js to this
    message, in case you would like to see it, but doing so seems to
    prevent me from sending the mail successfully. I doubt it is anything
    special.)

    Noodle 3: Searching for 'locale' in the preference file for the user
    profile I selected (default):

    carroll@funafuti:0 ~$ grep locale ~/.mozilla/firefox/********.default/prefs.js
    user_pref("extensions.ui.locale.hidden", false);

    Noodle 4: Yesterday, when I installed firefox-esr and performed some preliminary testing, I had

    LANG=fr_FR.UTF-8

    in /etc/default/locale

    instead of

    LANG=en_US.UTF-8

    I used update-locale last night to change LANG to its present value (en_US.UTF-8), and rebooted, to see if that would affect the test
    results with respect to 12-hour vs 24 hour clock format.

    I was unable to see any effect, regarding the results of your test.

    That is all I can think of to share.

    --- PyGate Linux v1.5.2
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)
  • From Max Nikulin@3:633/10 to All on Friday, January 09, 2026 08:50:02
    Notice date and time format in the next line.

    On 08/01/2026 2:09 am, Davidson wrote:
    On Tue, 6 Jan 2026, Max Nikulin wrote:

    Some aspects of locales and timestamp formatting have been discussed
    recently.

    I have not been around here lately, and did not see that discussion.

    An almost random post from that thread:

    Andrew M.A. Cater. Re: locales design and timezone (was:
    dpkg-reconfigure unable to change greeter locale) Sat, 27 Dec 2025
    19:14:09 +0000. <https://lists.debian.org/msgid-search/aVAwAWaAxi8l3LZk@einval.com>

    I'm running bullseye (which is currently oldoldstable).
    [...]
    carroll@funafuti:0 ~$ locale
    LANG=en_US.UTF-8
    LANGUAGE=
    [...]
    carroll@funafuti:0 ~$ LANG=en_GB.utf8 LANGUAGE=en_US:en firefox-esr ./html/home.html
    [...]
    carroll@funafuti:0 ~$ LANG=en_US.utf8 LANGUAGE=en_US:en firefox-esr ./html/home.html
    [...]
    This is what I see when LANG=en_GB.utf8 [...]
    https://en.wikipedia.org/wiki/Poop 06/01/2026, 13:14
    [...]
    And this is what I see when LANG=en_US.utf8 [...]
    https://en.wikipedia.org/wiki/Poop 1/06/2026, 13:14

    As you can see, apparently I have a 24-hour clock in either case.

    Thank you for a data point.

    I have realized that I have a VM with Debian 13 trixie and almost
    default XFCE. I see the same 12h am/pm and the same priority of LANGUAGE
    over LANG and LC_TIME for time formatting as on the host. So it should
    not be KDE specific or caused by missing recommended packages.

    It seems, order of variables in environment memory block does not matter.

    A have not noticed differences in Debian patches for Firefox-140 in
    bookworm and trixie.

    My current hypothesis is that something has been changed in Gtk. I have
    not noticed anything related to 12h vs 24h in my ~/.config/gtk*. There
    is a little chance that the issue caused by some uninitialized value in
    the code.

    I have realized that thunderbird citation header may be a more
    convenient entry point since I know rather unique keyword to search for. "History" or "language" might be too generic. So far I have traced
    called functions to <https://searchfox.org/comm-central/source/mozilla/intl/locale/gtk/OSPreferences_gtk.cpp>
    that has some interesting comments. I plan to continue later.

    --- PyGate Linux v1.5.2
    * Origin: Dragon's Lair, PyGate NNTP<>Fido Gate (3:633/10)