[bionic] Extended characters in GNOME screen keyboard don't get entered

Bug #1761554 reported by Jeremy Bícha
18
This bug affects 2 people
Affects Status Importance Assigned to Milestone
gnome-shell (Ubuntu)
Triaged
Medium
Jeremy Bícha
Bionic
Triaged
Medium
Jeremy Bícha
gnome-user-docs (Ubuntu)
Confirmed
Undecided
Unassigned
Bionic
Confirmed
Undecided
Unassigned
im-config (Ubuntu)
Triaged
Medium
Gunnar Hjalmarsson
Bionic
Triaged
High
Gunnar Hjalmarsson

Bug Description

im-config SRU request
=====================

[Impact]

When in a Wayland session, accented characters as well as some special characters can't be entered via the screen keyboard. The issue is fixed via the proposed upload of im-config, which has been changed to not set the GTK_IM_MODULE environment variable for IBus on Wayland (previously GTK_IM_MODULE was set to "ibus").

Making this accessibility tool work without issues on Wayland is important enough to justify this SRU.

[Test Case]

1. Log in to an Ubuntu on Wayland session

2. Open gedit and enable the screen keyboard
   (Settings -> Universal Access -> Typing)

-> Accented characters via long-press does not work.
   Example: long-press a and select à from the popup

   Also, certain keys for special characters result in incorrect
   characters or nothing. Examples: ~, √, ÷, ×, <, >, ¢

3. Install im-config from bionic-proposed

4. Relogin and repeat step 2.

-> Everything works as expected

[Regression Potential]

There are reasons to presuppose that GTK_IM_MODULE does not need to be set at all for IBus on a GNOME desktop:

* GTK has a mechanism for selecting a built-in IM.

* IBus is default in GNOME, and vanilla GNOME (which does not make use
  of im-config) does not set the GTK_IM_MODULE environment variable.

But the change is only made for Wayland sessions, which is not default in 18.04. Given this limitation, the regression risk is deemed to be low.

[Original description]

I filed this bug upstream last month but it hasn't gotten much attention so I'm filing it here because I think we need to track this issue for the Ubuntu 18.04 release

https://gitlab.gnome.org/GNOME/gnome-shell/issues/109

Test Case
---------
1. Open the Settings app. Click Universal Access.
2. Enable the Screen Keyboard. (Optionally, turn on "Always Show Universal Access Menu" to make turning the Screen Keyboard on and off easier.)
3. Open Text Editor
4. Click the u button on the Screen Keyboard
5. Long-press the u button on the Screen Keyboard for a few seconds. On the popup, click the ü character.

What Happens
------------
In Step 4, u is entered in the Text Editor document.

Nothing is entered in Step 5.

This bug affects any of the "extended characters" clicked on from the long-press popup in the Screen Keyboard.

Jeremy Bícha (jbicha)
description: updated
tags: added: osk
Will Cooke (willcooke)
Changed in gnome-shell (Ubuntu):
assignee: nobody → Jeremy Bicha (jbicha)
tags: removed: rls-bb-incoming
Revision history for this message
Jeremy Bícha (jbicha) wrote :

Gunnar, please see my comments at https://gitlab.gnome.org/GNOME/gnome-shell/issues/109#note_98033

Can we stop setting GTK_IM_MODULE=ibus at least in the GNOME and Ubuntu sessions?

Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :

@Jeremy: Your workaround with not setting GTK_IM_MODULE makes me think of bug #1760308, where that would have been an alternative solution (see comment #6). Now Sebastien fixed it in IBus instead.

To stop setting GTK_IM_MODULE would be an easy thing in im-config, of course. I'm hesitating since we have set that variable to ibus for many cycles, and we are very late in the cycle. I don't understand the significance of setting it, and I think it would be desirable to at least consult with one or two IM users before making that change.

Or maybe Sebastien, who is already familiar with the IBus changes which screwed up things wrt Ctrl+Shift+U, can give us a hint offhand on what could be done on the IBus side.

Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :

Hmm.. I now see that the issue is present in 17.10 too, so it's probably due to something else but the latest IBus changes which affected Ctrl+Shift+U.

I also see that some extended characters work. For instance, the letters å, ä and ö, which are in the Swedish alphabet, work for me. Weird.

Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :

After having read one of Carlos' comments in the upstream issue, I switched to a German XKB layout and was then able to type ü via the screen keyboard.

Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :

Did some testing on bionic.

It appears to me as if the feature is designed solely for Wayland. Yes, on Wayland with GTK_IM_MODULE unset it seems to work without issues. On Wayland with GTK_IM_MODULE=ibus I can reproduce the issues as described above.

On Xorg the feature works very poorly irrespective of the value of GTK_IM_MODULE. Basically you can only type the characters you see on the first instance of the screen keyboard (which depends on the effective XKB layout). Capitalized letters get typed as small letters, and most extended characters don't result in anything or some wrong character.

Considering that Xorg will be default in 18.04, would it be worth the regression risk to stop im-config from setting GTK_IM_MODULE this late in the cycle in order to fix the feature on Wayland?

Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :

How about handling this through the docs for now?

https://gitlab.gnome.org/gunnarhj/gnome-user-docs/commit/05003485

Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :

This Debian bug report is touches this issue:

https://bugs.debian.org/877312

Osamu Aoki (the im-config maintainer):
> If ibus is started outside of im-config, it may be better to
> automatically set im-config to set to "REMOVE".

Revision history for this message
Sebastien Bacher (seb128) wrote :

Gunnar, what do you want to change in the documentation there?

Changed in gnome-user-docs (Ubuntu):
status: New → Incomplete
Changed in gnome-user-docs (Ubuntu Bionic):
status: New → Incomplete
Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :

Hmm.. I deleted that fork of gnome-user-docs without remembering to preserve that snippet.

But the idea was to tell the user to:

1. Switch the input method to "none"

2. Log in to a Wayland session

OTOH, if we would change im-config to not set set GTK_IM_MODULE when IBus is the selected input method, the docs hint would only need to include item 2.

This, of course, only applies if we don't figure out a way to make it work also in X.

Changed in gnome-user-docs (Ubuntu):
status: Incomplete → New
Changed in gnome-user-docs (Ubuntu Bionic):
status: Incomplete → New
Changed in im-config (Ubuntu):
assignee: nobody → Gunnar Hjalmarsson (gunnarhj)
importance: Undecided → Medium
status: New → Fix Committed
Changed in im-config (Ubuntu Bionic):
assignee: nobody → Gunnar Hjalmarsson (gunnarhj)
importance: Undecided → Medium
status: New → In Progress
description: updated
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package im-config - 0.34-1ubuntu2

---------------
im-config (0.34-1ubuntu2) cosmic; urgency=medium

  * debian/patches/dont-set-GTK_IM_MODULE-on-wayland.patch:
    - Don't set GTK_IM_MODULE if IBus on Wayland session
      (LP: #1761554).

 -- Gunnar Hjalmarsson <email address hidden> Thu, 24 May 2018 23:54:00 +0200

Changed in im-config (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Łukasz Zemczak (sil2100) wrote : Please test proposed package

Hello Jeremy, or anyone else affected,

Accepted im-config into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/im-config/0.34-1ubuntu1.1 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed.Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Changed in im-config (Ubuntu Bionic):
status: In Progress → Fix Committed
tags: added: verification-needed verification-needed-bionic
Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :

Went through the steps in the test case. A relogin in step 4. proved to not be sufficient; rebooting was needed. Besides that I verified the test case using im-config 0.34-1ubuntu1.1 from bionic-proposed.

tags: added: verification-done verification-done-bionic
removed: verification-needed verification-needed-bionic
Revision history for this message
Iain Lane (laney) wrote :

rls-bb-notfixing means that this doesn't need to be tracked as a team release-critical bug; anyone else should feel free to work on the remaining items

tags: added: rls-bb-notfixing
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package im-config - 0.34-1ubuntu1.1

---------------
im-config (0.34-1ubuntu1.1) bionic-proposed; urgency=medium

  * debian/patches/dont-set-GTK_IM_MODULE-on-wayland.patch:
    - Don't set GTK_IM_MODULE if IBus on Wayland session
      (LP: #1761554).

 -- Gunnar Hjalmarsson <email address hidden> Thu, 24 May 2018 23:54:00 +0200

Changed in im-config (Ubuntu Bionic):
status: Fix Committed → Fix Released
Revision history for this message
Chris Halse Rogers (raof) wrote : Update Released

The verification of the Stable Release Update for im-config has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :

@Jeremy: Do you think there is a Bionic solution for X in sight? If not, I still think that a note in the docs (saying that it works only on Wayland) would be appropriate.

Revision history for this message
Nicolas Schmitt (lilalas) wrote :

I feel like the update im-config 0.34-1ubuntu1.1 bugged out ibus-mozc on Wayland.

I'm getting crashes in LibreOffice---and in some other applications (Gnome shell search bar), the candidate window is not showing up. It was definitely working at some point before this update.

Could be that I'm wrong about this update causing this, I'm not really sure ... Someone else experiencing similar issues?

Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :

On 2018-06-09 22:08, Nicolas Schmitt wrote:
> I feel like the update im-config 0.34-1ubuntu1.1 bugged out ibus-mozc
> on Wayland.
>
> I'm getting crashes in LibreOffice---and in some other applications
> (Gnome shell search bar),

Thanks for reporting this. I can confirm it with ibus-mozc and LibreOffice. Same problem with ibus-libpinyin. (I think I only tested with gedit, where it works, before making the change...)

Even if Wayland is not default in Ubuntu 18.04, this regression is too serious to be acceptable. I'm going to reverse the change.

Thanks again!

Changed in im-config (Ubuntu):
status: Fix Released → In Progress
Changed in im-config (Ubuntu Bionic):
status: Fix Released → In Progress
importance: Medium → High
tags: added: regression-update
Changed in im-config (Ubuntu):
status: In Progress → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package im-config - 0.34-1ubuntu3

---------------
im-config (0.34-1ubuntu3) cosmic; urgency=medium

  * debian/patches/dont-set-GTK_IM_MODULE-on-wayland.patch:
    - Dropped. The 0.34-1ubuntu2 changes reversed due to regression,
      e.g. LibreOffice crash when using IBus (LP: #1761554).

 -- Gunnar Hjalmarsson <email address hidden> Sun, 10 Jun 2018 21:55:00 +0200

Changed in im-config (Ubuntu):
status: Fix Committed → Fix Released
Revision history for this message
Brian Murray (brian-murray) wrote : Please test proposed package

Hello Jeremy, or anyone else affected,

Accepted im-config into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/im-config/0.34-1ubuntu1.2 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed.Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

Changed in im-config (Ubuntu Bionic):
status: In Progress → Fix Committed
tags: added: verification-needed verification-needed-bionic
removed: verification-done verification-done-bionic
Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :

Installed im-config 0.34-1ubuntu1.2 from bionic-proposed, rebooted, and started a Wayland session. Could input Japanese and Chinese characters in LO Writer using ibus-mozc respective ibus-libpinyin without LO Writer crashing, so this version fixes the regression reported in comment #17.

tags: added: verification-done verification-done-bionic
removed: verification-needed verification-needed-bionic
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package im-config - 0.34-1ubuntu1.2

---------------
im-config (0.34-1ubuntu1.2) bionic-proposed; urgency=medium

  * debian/patches/dont-set-GTK_IM_MODULE-on-wayland.patch:
    - Dropped. The 0.34-1ubuntu1.1 changes reversed due to regression,
      e.g. LibreOffice crash when using IBus (LP: #1761554).

 -- Gunnar Hjalmarsson <email address hidden> Sun, 10 Jun 2018 22:08:00 +0200

Changed in im-config (Ubuntu Bionic):
status: Fix Committed → Fix Released
Revision history for this message
Jeremy Bícha (jbicha) wrote :

I am reopening the im-config task since the underlying bug is still not fixed.

Changed in im-config (Ubuntu):
status: Fix Released → Triaged
Changed in im-config (Ubuntu Bionic):
status: Fix Released → Triaged
Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :

@Jeremy: My failed attempt to address the issue for Wayland indicates that this issue is complex. Maybe there is a need to tweak ibus itself somehow.

Revision history for this message
Launchpad Janitor (janitor) wrote :

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

Changed in gnome-user-docs (Ubuntu Bionic):
status: New → Confirmed
Changed in gnome-user-docs (Ubuntu):
status: New → Confirmed
Revision history for this message
Gunnar Hjalmarsson (gunnarhj) wrote :

My understanding is that this bug has been taken care of through the fixes of bug #1760399 and bug #1816808. Marking it a duplicate of the former.

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.