Bug 487810

Summary: adding and changing languages gives me an error even though it works
Product: [Applications] systemsettings Reporter: potato4u <eli.weism>
Component: kcm_regionandlangAssignee: Plasma Bugs List <plasma-bugs>
Status: RESOLVED DUPLICATE    
Severity: normal CC: hanyoung
Priority: NOR Keywords: accessibility, usability
Version: 6.0.5   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description potato4u 2024-05-30 19:31:44 UTC
SUMMARY
I have a fresh fedora 40 installation with the language set to german (switzerland). when i want to add a language or change the current one, after selecting a language the following message appears:
"Could not find the system's available locales using the localectl tool. Please file a bug report about this at https://bugs.kde.org"
But after a restart, the language is changed/added and works and no error message shows up in settings.
localectl outputs the following though:
System Locale: LANG=de_CH.UTF-8
    VC Keymap: ch
   X11 Layout: ch
    X11 Model: pc105


SOFTWARE/OS VERSIONS
Linux/KDE Plasma: fedora 40
(available in About System)
KDE Plasma Version: 6.0.5
KDE Frameworks Version: 6.2.0
Qt Version: 6.7.1

ADDITIONAL INFORMATION
Comment 1 potato4u 2024-05-31 09:15:44 UTC
I had some more time today to investigate the issue:
changing the language in the settings doesn't change /etc/locale.conf. If that is intended or not, i do not know. (If not, might be a good option in the future to be able to apply the locale settings to /etc/locale.conf?)
the command locale outputs the correct values set by the Region & Language settings. (~/.config/plasma-localerc)
Right now i have the following setup:

/etc/locale.conf:
System Locale: LANG=en_US.UTF-8
    VC Keymap: ch
   X11 Layout: ch
    X11 Model: pc105

~/.config/plasma-localerc:
[Formats]
LANG=en_US.UTF-8
LC_ADDRESS=de_CH.UTF-8
LC_MEASUREMENT=de_CH.UTF-8
LC_MONETARY=de_CH.UTF-8
LC_NAME=de_CH.UTF-8
LC_NUMERIC=de_CH.UTF-8
LC_PAPER=de_CH.UTF-8
LC_TELEPHONE=de_CH.UTF-8
LC_TIME=de_CH.UTF-8

[Translations]
LANGUAGE=en_US:de

output of command locale:

LANG=en_US.UTF-8
LC_CTYPE="en_US.UTF-8"
LC_NUMERIC=de_CH.UTF-8
LC_TIME=de_CH.UTF-8
LC_COLLATE="en_US.UTF-8"
LC_MONETARY=de_CH.UTF-8
LC_MESSAGES="en_US.UTF-8"
LC_PAPER=de_CH.UTF-8
LC_NAME=de_CH.UTF-8
LC_ADDRESS=de_CH.UTF-8
LC_TELEPHONE=de_CH.UTF-8
LC_MEASUREMENT=de_CH.UTF-8
LC_IDENTIFICATION="en_US.UTF-8"
LC_ALL=

so, in summary, changing the settings in Region & Language works, but the error message:
"Could not find the system's available locales using the localectl tool. Please file a bug report about this at https://bugs.kde.org"
still persists
Comment 2 hanyoung 2024-05-31 12:53:08 UTC

*** This bug has been marked as a duplicate of bug 479213 ***