Skip to content
This repository has been archived by the owner on Mar 2, 2019. It is now read-only.

Migrate to txdbus #62

Open
micolous opened this issue Feb 2, 2014 · 1 comment
Open

Migrate to txdbus #62

micolous opened this issue Feb 2, 2014 · 1 comment

Comments

@micolous
Copy link
Owner

micolous commented Feb 2, 2014

Presently, tollgate uses dbus-python in order to talk over DBus. This has some major problems:

  • It requires that a binary module be compiled
  • It can't run inside of a virtualenv
  • It uses autotools rather than distutils for packaging, meaning pip can't install it.
  • It doesn't appear to be actively maintained.

A lot of this centres around this bug.

There's another implementation of DBus, written in Python (without a native library), called txdbus. This is written using Twisted.

This would require that the existing dbus code be ported to Twisted. This also has the bonus of being able to use Twisted's daemonisation instead of daemonize which can refer to about three different distinct packages with the same egg name.

@micolous
Copy link
Owner Author

I've ported micolous/cbus to txdbus in a branch, and it seems to work well. Some gotchas:

  • All of the methods use Twisted Deferred objects, which requires some wrapping around (defer.inlineCallbacks), but this prevents the methods from returning a value.
  • Subjective examinations show that txdbus is much faster than python-dbus.
  • Tollgate's backend daemon will need to be ported to twisted (but this is probably good as it means it could maybe run in twistd)

Need to keep these in mind when porting tollgate.

micolous added a commit that referenced this issue Apr 24, 2014
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant