Bug 948723

Summary: Software Management: Patterns are listed in Finnish even English is chosen as Language
Product: [openSUSE] openSUSE Tumbleweed Reporter: Olli Tuominen <olli.tuominen>
Component: YaST2Assignee: E-mail List <yast2-maintainers>
Status: RESOLVED INVALID QA Contact: Jiri Srain <jsrain>
Severity: Normal    
Priority: P5 - None CC: ancor, locilka, olli.tuominen
Version: Current   
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: screenshot
y2logs
kde system settings
zypper.conf
zypp.conf
ncurces yast

Description Olli Tuominen 2015-10-04 17:42:12 UTC
Created attachment 650029 [details]
screenshot

LEAP: Beta1
See screenshot. Language is setup as English.
Translations has been setup as American English too, Format has been set as Sumoi-suomi (fi_FI)
Comment 1 Lukas Ocilka 2015-10-06 12:53:46 UTC
Please attach Yast logs
There must be a reason for that which is not obvious without logs.
Comment 2 Lukas Ocilka 2015-10-07 15:04:33 UTC
Or at least tell us how exactly to reproduce, thx
Comment 3 Olli Tuominen 2015-10-08 06:48:51 UTC
Created attachment 650617 [details]
y2logs
Comment 4 Olli Tuominen 2015-10-08 06:52:52 UTC
I think it something to do with locale or kde system settings format - see next attachment. Otherwise this is straight from the media.

localectl 
   System Locale: LANG=POSIX
                  LC_CTYPE=en_US.UTF-8
       VC Keymap: fi
      X11 Layout: fi
       X11 Model: pc105
     X11 Options: terminate:ctrl_alt_bksp
Comment 5 Olli Tuominen 2015-10-08 06:53:15 UTC
Created attachment 650620 [details]
kde system settings
Comment 6 Lukas Ocilka 2015-10-08 07:37:50 UTC
OK, so (info from logs) the installation was performed with these settings:

Language: English
Keyboard: Finnish
Timezone: Europe/Helsinki
Desktop:  KDE

Nothing else that could change it...
Comment 7 Olli Tuominen 2015-10-08 08:00:40 UTC
Im not sure if this is related that also the time is translated to Finnish:
https://bugzilla.suse.com/show_bug.cgi?id=931171

Do you need something more from me at the moment?
Comment 8 Lukas Ocilka 2015-10-08 09:00:03 UTC
Well, you could try running Yast Qt in GNOME and also text-mode Yast (ncurses)
in Xterm or so. Does it still produce the same result?
Comment 9 Lukas Ocilka 2015-10-08 09:06:03 UTC
Wait, this looks like a libzypp issue, this comes from logs:

y2log:

modules/Misc.rb:189 .sysconfig.language.RC_LANG: 'en_US.UTF-8'
modules/Language.rb:508 language from sysconfig: en_US
modules/Language.rb:440 original language: en_US; setting to lang:en_US
modules/Misc.rb:189 .sysconfig.language.RC_LANG: 'en_US.UTF-8'

and later

modules/PackageLock.rb:146 Pkg Builtin called: Connect
PkgFunctions.cc(zypp_ptr):100 Initializing Zypp library...
[zconfig] ZConfig.cc(_autodetectTextLocale):202 Found LANG=fi_FI.UTF-8
[zconfig] ZConfig.cc(_autodetectTextLocale):209 Default text locale is 'fi_FI'
...
[zconfig] ZConfig.cc(ZConfig):794 zypp.conf: '/etc/zypp/zypp.conf'
[zconfig] ZConfig.cc(ZConfig):794 TextLocale: 'fi_FI' (fi_FI)

Looks like:
Yast runs in en_US
libzypp detects fi_FI

Olli, can you attach your /etc/zypp/zypp.conf please?
Comment 10 Olli Tuominen 2015-10-08 09:34:42 UTC
Created attachment 650664 [details]
zypper.conf
Comment 11 Olli Tuominen 2015-10-08 09:35:13 UTC
Created attachment 650666 [details]
zypp.conf
Comment 12 Olli Tuominen 2015-10-08 09:37:15 UTC
Created attachment 650671 [details]
ncurces yast
Comment 13 Michael Andres 2015-10-13 17:13:37 UTC
(In reply to Lukas Ocilka from comment #9)
> PkgFunctions.cc(zypp_ptr):100 Initializing Zypp library...
> [zconfig] ZConfig.cc(_autodetectTextLocale):202 Found LANG=fi_FI.UTF-8
> [zconfig] ZConfig.cc(_autodetectTextLocale):209 Default text locale is
> 'fi_FI'
> ...
> [zconfig] ZConfig.cc(ZConfig):794 zypp.conf: '/etc/zypp/zypp.conf'
> [zconfig] ZConfig.cc(ZConfig):794 TextLocale: 'fi_FI' (fi_FI)
> 
> Looks like:
> Yast runs in en_US
> libzypp detects fi_FI

zypp derives the default text locale from $LANG, which is 'fi_FI.UTF-8'. 

If yast want's a different language, it must call ZConfig::setTextLocale. If the locale yast requests differs from the current setting, you'll see a log line from  ZConfig.cc telling "Overriding text locale (OLDLANG): NEWLANG"; later a line from PoolImpl.cc "pool_set_languages: NEWLANG and it's fallbacks"

I don't see yast requesting a different locale in the logs...
Comment 14 Olli Tuominen 2015-11-06 07:36:44 UTC
Just installed Leap and there is same problem.
Comment 15 Ancor Gonzalez Sosa 2015-11-09 16:06:04 UTC
Olli, could you execute "locale" (not localectl) and paste the output?
Comment 16 Olli Tuominen 2015-11-09 19:13:20 UTC
~> locale
LANG=fi_FI.UTF-8
LC_CTYPE="fi_FI.UTF-8"
LC_NUMERIC="fi_FI.UTF-8"
LC_TIME="fi_FI.UTF-8"
LC_COLLATE="fi_FI.UTF-8"
LC_MONETARY="fi_FI.UTF-8"
LC_MESSAGES="fi_FI.UTF-8"
LC_PAPER="fi_FI.UTF-8"
LC_NAME="fi_FI.UTF-8"
LC_ADDRESS="fi_FI.UTF-8"
LC_TELEPHONE="fi_FI.UTF-8"
LC_MEASUREMENT="fi_FI.UTF-8"
LC_IDENTIFICATION="fi_FI.UTF-8"
LC_ALL=
Comment 17 Ancor Gonzalez Sosa 2015-11-10 15:48:37 UTC
Ok. Reproduced.

So the point is that you have the LANGUAGE env variable ("translations" section of KDE control panel) forced to en_US and you have the LANG variable ("format" section) set to fi_FI.UTF-8.

To be honest, having the UI in English and the pattern names in Finish is the smallest problem I would expect from having inconsistent LANG and LANGUAGE variables. :-)

Actually, taking into account the meaning of both variables, I'd even say that the result, UI in English with data in Finish, can be considered perfectly correct.

Closing as invalid. Feel free to reopen if you disagree.