[Pkg-utopia-maintainers] Bug#802659: dbus-python: Please drop recommends on PyQt4 packages

Simon McVittie smcv at debian.org
Wed Jan 20 09:15:24 UTC 2016


Sorry for the delay in responding to this; dbus-python hasn't been high
on my priority list.

On Thu, 22 Oct 2015 at 12:29:54 +0300, Dmitry Shachnev wrote:
>   Drop obsolete recommendations of Qt 4 packages
...
>   * python3-dbus.mainloop.qt is a package providing support for Qt (4.x) main
>     loop. However, Qt uses GLib main loops on UNIX systems by default, so this
>     package is needed very rarely and we should not recommend it.

I'd be happy enough to do this, but I'd like to give the Qt/KDE
maintainers (Cc'd) the opportunity to object first, so that if I get
bug reports asking me to revert the change because someone feels that
python[3]-gi is insufficiently desktop-neutral, I can point the bug
reporter to the relevant discussion and close the bug.

The library can be used without main loop support, and it doesn't
really care which main loop glue you use (options are currently GLib,
(GLib via) Qt, or E); but the majority of its functionality relies
on having *some* main loop glue for dbus-python, and then running a
compatible main loop in your program.  I included the Recommends so
that "apt install python{,3}-dbus" would give users enough modules to
run locally-written programs similar to dbus-python's own examples.
See <https://bugs.debian.org/656230> for further context.

(Anything that specifically imports dbus.mainloop.whatever should of course
continue to depend on the appropriate package.)

This main loop glue nonsense is an artefact of dbus-python trying hard
to be non-desktop-specific. With hindsight, that was a bad idea, and
these days I much prefer self-contained D-Bus implementations/bindings
(GDBus, QtDBus, sd-bus) that assume a particular main-loop framework
and can benefit from being properly integrated with it.

>   * python-qt4-dbus is a replacement for dbus-python; if one uses one package,
>     he will not need the other.

Really? It looks a lot like a direct equivalent of python3-dbus.mainloop.qt
to me:

% dpkg -L python-qt4-dbus
[... the usual /usr/share/doc noise ...]
[... some directories ... ]
/usr/lib/python2.7/dist-packages/dbus/mainloop/qt.so

Its name is presumably for historical reasons; if it was created today,
it would be named python-dbus.mainloop.qt.

At the time dbus-python was written, PyQt did not bind QtDBus; now it
does (which I believe was partially a response to how long it took to
make dbus-python work in Python 3), and I would advise developers who are
using Python with Qt to consider using the QtDBus bindings in preference
to dbus-python. dbus-python is not actually a great API, and has
several historical design mistakes, which we can't correct because its
most significant advantage over other D-Bus bindings/implementations
is compatibility with older versions of itself. I haven't tried QtDBus
but I suspect it may be better, or at least present a more Qt-like API.

>   In the description of python-dbus-dev, replace dbus.mainloop.qt with
>   dbus.mainloop.pyqt5, which is the modern successor of dbus.mainloop.qt.

Done in git, thanks.

>   Also, drop the alternative recommendation for python-gobject-2. That
>   package has been deprecated for a long time and we want to remove it from
>   the archive as soon as possible.

Also done, thanks.

I'll apply the remaining changes (losing the Qt equivalents from
Recommends) if there's consensus that this is what people who like
Qt want me to do.

    S



More information about the Pkg-utopia-maintainers mailing list