unity actively overrides system-wide gsettings as current user, making some vendor overrides ineffective

Bug #1418939 reported by ccyqllus
24
This bug affects 5 people
Affects Status Importance Assigned to Milestone
Unity
Confirmed
Undecided
Unassigned
unity (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

How to reproduce:
as root execute
# echo -e "[org.gnome.desktop.input-sources]\nsources=[('xkb', 'us'), ('xkb', 'hu')]\n\n" >> /usr/share/glib-2.0/schemas/99_my.gschema.override
# echo -e "[org.compiz.unityshell]\nlauncher-minimize-window=true\n\n" >> /usr/share/glib-2.0/schemas/99_my.gschema.override
# glib-compile-schemas /usr/share/glib-2.0/schemas
and, either remove contents of home directory or create a new user,
and, reboot and log in as the appropriate user.

Result is that launcher-minimize-window settings=true as expected and launcher behaves accordingly, however input sources is just [('xkb', 'us')], where as it should be [('xkb', 'us'), ('xkb', 'hu')].

The launcher-minimize-window is just a random example. For most settings the vendor override method works.

But for a few, like "org.gnome.desktop.input-sources sources", they will not take effect, as some process, related to Unity, will override them for the current user after login.

Proof of this, is that running `gsettings reset org.gnome.desktop.input-sources sources` will result in [('xkb', 'us'), ('xkb', 'hu')], and the panel offering both layouts. Hence the vendor-override-method of setting system-wide defaults does work, but Unity ruins it for a few settings.

The proof that this bug is in Unity is that, installing another desktop environment, like gnome-shell, and logging into it, leaves all the system-wide defaults effective.

This bug makes vendor overrides, that should affect all "fresh" user accounts, ineffective.

The appropriate behaviour would be that a new user, or one that has its home directory cleared, to have the system-wide default gsettings in effect for their unity session.

Original problem statement: http://askubuntu.com/questions/582083/what-is-overriding-the-systemwide-keyboard-layout-settings

To get a more comprehensive but still incomplete listing of the settings that Unity overrides, log in into a "fresh" Unity session,
$ gsettings list-recursively >/tmp/01
$ gsettings list-schemas | xargs -n 1 gsettings reset-recursively
$ gsettings list-recursively >/tmp/02
$ diff /tmp/0* | less
This listing is incomplete, because it only lists non-relocatable schemas, and also because your system-wide defaults may match those of what Unity sets the users settings to. For example, not changing the layout setting to "[('xkb', 'us'), ('xkb', 'hu')]" with a vendor override, would cause it not to be listed.

Andrea Azzarone (azzar1)
Changed in unity:
status: New → Confirmed
Changed in unity (Ubuntu):
status: New → Confirmed
Revision history for this message
Ryan Tandy (rtandy) wrote :

I think the indicator-keyboard code for migrating settings is responsible, at least for the layout setting. I worked around it by writing a gschema override for org.gnome.libgnomekbd.keyboard.layouts, the old location where settings are migrated from, instead of org.gnome.desktop.input-sources.sources.

http://bazaar.launchpad.net/~indicator-applet-developers/indicator-keyboard/trunk/view/head:/lib/main.vala#L389

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

Other bug subscribers

Remote bug watches

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