Arch Linux

Please read this before reporting a bug:

Do NOT report bugs when a package is just outdated, or it is in Unsupported. Use the 'flag out of date' link on the package page, or the Mailing List.

REPEAT: Do NOT report bugs for outdated packages!

FS#62995 - [ibus] Hard dependency on on python2-dbus

Attached to Project: Arch Linux
Opened by Bernie Innocenti (codewiz) - Monday, 24 June 2019, 15:17 GMT
Last edited by Felix Yan (felixonmars) - Sunday, 17 January 2021, 17:59 GMT
Task Type General Gripe
Category Packages: Extra
Status Closed
Assigned To Felix Yan (felixonmars)
Architecture All
Severity Low
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 18
Private No


ibus-1.5.20-2 is the last package on my desktop still having dependencies on Python 2.

The ibus RPM in Fedora 30 does not have any dependencies on Python 2, so it should be possible to build it the same way on Arch.
This task depends upon

Closed by  Felix Yan (felixonmars)
Sunday, 17 January 2021, 17:59 GMT
Reason for closing:  Fixed
Additional comments about closing:  ibus-1.5.23+3+gaa558de8-3
Comment by Chih-Hsuan Yen (yan12125) - Monday, 24 June 2019, 17:08 GMT
A bit of history: python2-* dependecies are added due to Maybe those dependencies can be moved from ibus to ibus-googlepinyin and ibus-sunpinyin.
Comment by Alvaro García (rainbyte) - Friday, 29 November 2019, 07:58 GMT
Ibus is one the few packages asking for python2, even calibre works with python3.

Please, remove the unneeded dependency. Thanks in advance!
Comment by Emil (xexaxo) - Friday, 07 February 2020, 15:30 GMT
From the ibus package we have three executables: ibus, ibus-daemon and ibus-setup.
Where only the last one depends on python.

As such, based on the wiki[1] one should use something like
'python-dbus: for ibus-setup'
'python-gobject: for ibus-setup'
'python2-gobject2: for ibus-setup'
'python2-dbus: for ibus-setup'
'python2-gobject: for ibus-setup'

Can we have something like this please?

Comment by loqs (loqs) - Friday, 07 February 2020, 17:21 GMT
@xexaxo do you start ibus-setup using `PYTHON=python2 ibus-setup` to force the use of python2?
Comment by Emil (xexaxo) - Friday, 07 February 2020, 18:08 GMT
@loqs nope - no python2 here ;-)

I'm using a local package which demotes python* as mentioned.
Installed python2* and had a quick test - PYTHON=python2 ibus-setup does bring the GUI prompting to start the daemon.
Comment by Alvaro García (rainbyte) - Saturday, 08 February 2020, 11:57 GMT
I'm using my own pkg now, without gtk2 nor python2
Comment by Emil (xexaxo) - Thursday, 26 March 2020, 18:43 GMT
@felixonmars humble poke?
Comment by Matthias Schiffer (NeoRaider) - Saturday, 02 May 2020, 10:38 GMT
On Debian, the ibus package has not used Python 2 for a looong time (only indirect dependencies in current oldoldstable, no dependencies in oldstable). I assume ibus-setup works fine with Python 3?

On Arch, ibus-googlepinyin does not exist anymore, and ibus-sunpinyin is using Python 3 by now; there are only a few remaining input methods like ibus-pinyin that use Python 2 (I have not checked all packages though)
(also, in Debian Testing, this was updated to Python 3 as well: )

It would be great if the Python 2 deps could be moved to the input method packages that actually require them.
Comment by Emil (xexaxo) - Monday, 04 May 2020, 10:10 GMT
@felixonmars how can we help move this forward?
Comment by loqs (loqs) - Tuesday, 29 September 2020, 05:09 GMT
PKGBUILD.ibus.diff drops all python2 support.  FS#42243  which added the python2 dependencies was for ibus-googlepinyin which is no longer packaged.
Only ibus-pinyin uses python2 of the current dependencies. PKGBUILD.ibus-pinyin.diff converts it to python3. Lua compatibility patch curtsy of Fedora.
PKGBUILD.sunpinyin.diff converts it to python3.
Updated PKGBUILD.ibus.diff to ibus 1.5.23 and to build with vala 50.
Comment by I Said Socks (socks) - Sunday, 18 October 2020, 11:49 GMT
Thumbs up to all offering a fix.

Yeah, ibus is the only package depending on python2 on my system now.
(BTW, python2-twisted & python2-incremental depend on each other so didn't show up in `pacman -Qtd`, nearly escaping the great broom of history ;)

On top of removing python2-* dependencies, Felix, please also remove ibus.install, since these are handled by alpm hooks already.
Comment by Alexander Michalopoulos (Nocifer) - Wednesday, 02 December 2020, 15:21 GMT

The ibus package was updated today, but apparently the python2 dependencies are still included, along with the outdated ibus.install file. Is there a particular reason for why these are still being kept around or is it just an accidental omission?
Comment by Felix Yan (felixonmars) - Thursday, 17 December 2020, 20:30 GMT
Implemented in ibus 1.5.23+3+gaa558de8-2, also moved gtk2 to makedepends only (it's only used in gtk2 immodule, which is only useful if gtk2 itself was installed).

Sorry for the very long delay.
Comment by Chih-Hsuan Yen (yan12125) - Sunday, 20 December 2020, 09:14 GMT
Thanks! I can confirm ibus 1.5.23+3+gaa558de8-2 works fine with ibus-chewing 1.6.1-5
Comment by Emil (xexaxo) - Wednesday, 23 December 2020, 14:18 GMT
@felixonmars thank you. 1.5.23+3+gaa558de8-2 works.

At install time an annoying "gtk-query-immodules-2.0 not found" message pops up.
You already removed ibus.install, perhaps it should be in the final package (-3)?
Comment by Felix Yan (felixonmars) - Sunday, 17 January 2021, 17:59 GMT
Fixed in ibus-1.5.23+3+gaa558de8-3.