Language installation doesn't work in Ubuntu GNOME 16.10 Settings app

Bug #1631750 reported by Jeremy Bicha on 2016-10-09
68
This bug affects 11 people
Affects Status Importance Assigned to Milestone
Ubuntu GNOME
High
Unassigned
gnome-control-center (Ubuntu)
High
Unassigned

Bug Description

What happens
============
1. From a terminal in Ubuntu GNOME, enter
 gnome-control-center region

My locale is set to en_US so my terminal emits
common-cc-panel-WARNING **: Language en_US.UTF-8 not installed, trying to install it

2. Click Language.
3. Click the 3-dot "more" button at the bottom of the popup.
4. Select French (France). Click Done.

My terminal emits:
common-cc-panel-WARNING **: Language fr_FR not installed, trying to install it

French isn't actually installed.

What should happen
==================
PackageKit should install French. Language in the main window should change from English (United States) to French (France). Unfortunately because of how the system works, it would still require a log out and log in for the change to actually take effect.

Other Info
===========
Installation of audio/video codes appears to work just fine:

1. Uninstall the extra codecs (assuming you clicked the box in the installer to install third-party softwarel)
sudo apt uninstall ubuntu-restricted-addons
sudo apt autoremove

Download this file
https://archive.org/download/buckminsterfullereverythingiknow01/01001.rm

It opens in Totem and session-installer prompts to install gstreamer1.0-plugins-ugly. Installation completed successfully and I was able to play the file.

ProblemType: Bug
DistroRelease: Ubuntu 16.10
Package: gnome-control-center 1:3.20.1-2ubuntu3
ProcVersionSignature: Ubuntu 4.8.0-19.21-generic 4.8.0-rc8
Uname: Linux 4.8.0-19-generic x86_64
ApportVersion: 2.20.3-0ubuntu7
Architecture: amd64
CurrentDesktop: GNOME
Date: Sun Oct 9 09:52:01 2016
InstallationDate: Installed on 2016-10-07 (1 days ago)
InstallationMedia: Ubuntu-GNOME 16.10 "Yakkety Yak" - Alpha amd64 (20161007)
ProcEnviron:
 TERM=xterm-256color
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: gnome-control-center
UpgradeStatus: No upgrade log present (probably fresh install)

Jeremy Bicha (jbicha) wrote :
Jeremy Bicha (jbicha) on 2016-10-09
description: updated
summary: - PackageKit integration does not work in Ubuntu GNOME 16.10
+ Language installation doesn't work in Ubuntu GNOME 16.10 Settings app
description: updated
Ubuntu QA Website (ubuntuqa) wrote :

This bug has been reported on the Ubuntu ISO testing tracker.

A list of all reports related to this bug can be found here:
http://iso.qa.ubuntu.com/qatracker/reports/bugs/1631750

tags: added: iso-testing
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in gnome-control-center (Ubuntu):
status: New → Confirmed
Gunnar Hjalmarsson (gunnarhj) wrote :

Can confirm the language installation issue.

tags: added: regression-release
Jeremy Bicha (jbicha) on 2016-10-09
Changed in ubuntu-gnome:
importance: Undecided → High
status: New → Confirmed
Jeremy Bicha (jbicha) wrote :

It also affects Ubuntu GNOME 16.04 LTS with the GNOME3 Staging PPA. gnome-control-center there is virtually the same as in yakkety. That suggests that this is not the fault of yakkety's PackageKit 1.1 update.

Tim (darkxst) wrote :

Looks like the dbus API has changed
common-cc-panel-DEBUG: Error getting PackageKit updates list: GDBus.Error:org.freedesktop.DBus.Error.InvalidArgs: Type of message, '(tuas)', does not match expected type '(tas)'

Tim (darkxst) wrote :

also what-provides in general seems broken:
 pkcon what-provides "locale(zh_CN)"

should return a list of packages!

Gunnar Hjalmarsson (gunnarhj) wrote :

It's probably not applicable, but bug #1541288 proposed that language-selector would switch to PackageKit in xenial, but the plan was dropped, and l-s is still using aptdaemon.

god (humper) wrote :

How come this isn't release-blocking bug?!

Gunnar Hjalmarsson (gunnarhj) wrote :

A workaround until this has been fixed is to install the language-selector-gnome package.

sudo apt install language-selector-gnome

It will add "Language Support" to Settings, and additional languages can be installed from there.

Jeremy Bicha (jbicha) on 2017-03-18
Changed in ubuntu-gnome:
milestone: none → zesty
Tim (darkxst) wrote :

This patch adapts to the new d-bus API for Packagekit "WhatProvides"

It still doesnt help however, since I suspect the underlying aptdaemon plugin provided by language-selector is not returning any results.

tags: added: patch
Gunnar Hjalmarsson (gunnarhj) wrote :

@Tim: While language-selector-gnome still depends on aptdaemon, language-selector-common does not, and the check-language-support command ought to work. Maybe there is something else.

Tim (darkxst) wrote :

Gunnar, ok I been out of the loop a bit the last while, with internet issues, but should finally have adsl soon. We were previously using the packagekit plugin provided by language-selector that pitti implemented, although pretty sure we are/were the only users of that.

I guess I recall packagekit no longer supports plugins also, so the backend will need to grow support for this. is Ubuntu still using apt backend for PAckagekit?

tags: removed: patch
Gunnar Hjalmarsson (gunnarhj) wrote :

To be honest, this is over my head, but I think that it uses aptdaemon somehow when installing languages from the language-selector-gnome GUI, and thus l-s is affected by bug #1673258.

Martin wrote language_support_pkgs.py a few years ago. Is that what you mean? In that case it's used by everyone, not just Ubuntu GNOME.

Tim (darkxst) wrote :

Yes, as part of that there was a packagekit plugin, don't think anyone else ever made use of that specifically though. And now packagekit does not support plugins, we will need to find another way to make it work.

Upstream aren't too interested in lang packs last I heard, since no other distro even has proper lang pack support.

tags: added: patch
Jeremy Bicha (jbicha) wrote :

I happened to be looking into this bug too this weekend.

(By the way, my earlier comment about this affecting Ubuntu 16.04 with the GNOME3 Staging PPA is wrong because this was caused by the PackageKit 0.8 > 1.1 transition.)

Tim, maybe check-language-support does what we need instead of pk's what-provides (which apparently was never hooked up on Debian anyway).

$ check-language-support -l fr_FR
firefox-locale-fr gnome-getting-started-docs-fr hunspell-fr hyphen-fr language-pack-fr language-pack-gnome-fr libreoffice-help-fr libreoffice-l10n-fr mythes-fr wfrench

$ check-language-support -l en_US
[no output since I have English (United States) installed]

$ check-language-support -l en_GB
hunspell-en-gb hyphen-en-gb libreoffice-help-en-gb libreoffice-l10n-en-gb

Fedora does have language packs and they show in GNOME Software>Addons>Localization.

Ubuntu and Debian's packagekit are in sync now and I believe they use the aptcc backend.

Gunnar Hjalmarsson (gunnarhj) wrote :

On 2017-04-02 17:45, Jeremy Bicha wrote:
> Tim, maybe check-language-support does what we need

I'm pretty sure it does. check-language-support is used by the installer.

Tim (darkxst) wrote :

we can probably add what-provides support to aptcc I think Matthias was open to adding that into the backend as a stop-gap (longer term I think it will end up as part of the appstream metadata). Should be easier than moving to check-language-support.

Jeremy Bicha (jbicha) wrote :

I thought it would be easier to pipe the output of check-language-support to PackageKit. (But I'm not sure how to implement that myself.)

Anyway, I talked to Matthias this weekend briefly too: https://bugs.debian.org/848544

Tim (darkxst) wrote :

I will try and take a look over the weekend and see if I can hook something up.

Jeremy Bicha (jbicha) on 2017-04-21
tags: added: gnome-17.10
Jeremie Tamburini (jeremie2) wrote :

I found the same problem with the language setup on Ubuntu 17.10.
This could be related to the new Gnome Settings (just let me know if you think I should open a new bug report).

I was running Ubuntu 17.10 in Italian language, previously installed with the old Gnome Settings. I wanted to switch to English language but I couldn't because of this bug.

Following the steps of the bug description, the only difference was the terminal warning: "Language it_IT not installed, trying to install it"
..which is a bit strange because the system was already set to Italian, I wanted to set the en_US.UTF-8.

I've noticed that while trying to change the language settings, the strings in /etc/default/locale don't change at all.

:::::: WORKAROUND

1- sudo nano /etc/default/locale
2- Comment or delete the existing strings end write the following:

LANG="en_US.UTF-8"
LANGUAGE="en"

If I want to go back to the Italian setup I just need to write the following:

LANG="it_IT.UTF-8"
LANGUAGE="it:en"

3- Press [Ctrl]+O and [Enter] to save the file. Press then [Ctrl]+X to exit from Nano editor.
4- Log-out and log-in again or restart the system. After the log-in the system is asking if you would like to update the names of the folders into $HOME (Desktop, Music, Video, etc..).

Nathan Haines (nhaines) wrote :

This issue is still present in artful.

tags: added: rls-aa-incoming
Gunnar Hjalmarsson (gunnarhj) wrote :

On 2017-09-27 14:37, Nathan Haines wrote:
> This issue is still present in artful.

Yes, but a workaround is in place: The "Manage Installed Languages" which opens Language Support.

Will Cooke (willcooke) wrote :

This has been worked around by adding the extra buttons, so we won't get round to fixing it this cycle. Added to BB incoming.

no longer affects: gnome-control-center (Ubuntu Artful)
tags: added: rls-bb-incoming
removed: rls-aa-incoming
John Smith (jds10) wrote :

I have what seems to be a variant of the same problem, but not fixable with the workaround mentioned above. I upgraded a couple of days ago from Ubuntu Gnome 17.4 to Ubuntu 17.10, and now various of my global locale settings are incorrect in Gnome Shell 3.26. I set all the LC_* variables to "en_GB.UTF-8" in /etc/default/locale, but the shell opens with a lot of them changed to Spanish equivalents (I live in Spain):

bash-4.4$ locale
LANG=en_GB.utf8
LANGUAGE=en_GB:en
LC_CTYPE=en_GB.UTF-8
LC_NUMERIC=es_ES.UTF-8
LC_TIME=es_ES.UTF-8
LC_COLLATE=en_GB.UTF-8
LC_MONETARY=es_ES.UTF-8
LC_MESSAGES=en_GB.UTF-8
LC_PAPER=es_ES.UTF-8
LC_NAME=es_ES.UTF-8
LC_ADDRESS=es_ES.UTF-8
LC_TELEPHONE=es_ES.UTF-8
LC_MEASUREMENT=es_ES.UTF-8
LC_IDENTIFICATION=es_ES.UTF-8
LC_ALL=

Switching from gdm3 to lightdm makes no difference. Starting fvwm instead of Gnome on xorg shows that the problem doesn't exist there, but -- to my surprise -- it does exist if I start Gnome flashback on Compiz. I can't try Unity, as it says my stored display settings prevent it from opening.

Gunnar Hjalmarsson (gunnarhj) wrote :

@John: What you describe is something else, and you'd better use the GUI to fix it:

Settings -> Region & Language -> Formats

You probably want to change it to United Kingdom.

John Smith (jds10) wrote :

@Gunnar: Thanks, but it is already set to United Kingdom (and the machine has been restarted several times). But my half-Spanish locale persists.

Gunnar Hjalmarsson (gunnarhj) wrote :

@John: Please show us the contents of ~/.pam_environment.

cat ~/.pam_environment

John Smith (jds10) wrote :

@Gunnar: Aha! The "mixed bag" locale is in there:

bombay:~$ cat .pam_environment
LANGUAGE=en_GB
LANG=en_GB.UTF-8
LC_NUMERIC=es_ES.UTF-8
LC_TIME=es_ES.UTF-8
LC_MONETARY=es_ES.UTF-8
LC_PAPER=es_ES.UTF-8
LC_NAME=es_ES.UTF-8
LC_ADDRESS=es_ES.UTF-8
LC_TELEPHONE=es_ES.UTF-8
LC_MEASUREMENT=es_ES.UTF-8
LC_IDENTIFICATION=es_ES.UTF-8
PAPERSIZE=a4

The timestamp on the file is June 8 2016, but I did not see the behaviour I describe before 17.10. And isn't the content of .pam_environment supposed to change to reflect the settings selected in the GUI tools?

When I have posted this I shall edit the file and re-login, and then post the result.

John Smith (jds10) wrote :

Things now back to normal. Many thanks!

Gunnar Hjalmarsson (gunnarhj) wrote :

On 2017-10-26 17:33, John Smith wrote:
> The timestamp on the file is June 8 2016, but I did not see the
> behaviour I describe before 17.10.

Right, it was due to bug #1662031.

> And isn't the content of .pam_environment supposed to change to
> reflect the settings selected in the GUI tools?

~/.pam_environment should be changed when you change Language or Format from the GUI. The fact that it looked like United Kingdom was set as Format indicates that things were out of sync. If you for instance change Format to something else, and then back to United Kingdom, I think you'll notice that ~/.pam_environment is changed accordingly.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.