Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Native Python implementation of DBus for Twisted
Python
Branch: master

Merge pull request #29 from jasonlife/master

DBus service hangs when you mix both big and small endian dbus clients at the same time
latest commit 106fb15980
@cocagne authored
Failed to load latest commit information.
doc tutorial.asciidoc: fix a typo
txdbus Fixed DBus service hanging problem by using both big and little endia…
.gitignore initial release
LICENSE LICENSE
MANIFEST.in Renamed package from tx.dbus to txdbus
README.md Switched to indirect python interpreter script reference and fixed th…
requirements.txt Partial support for Python 3.3+.
runtests.py Partial support for Python 3.3+.
setup.py
tox.ini Use "usedevelop" option.

README.md

TxDBus

Tom Cocagne tom.cocagne@gmail.com v1.0, July 2012

Introduction

TxDBus is a native Python implementation of the DBus protocol for the Twisted networking framework.

In addition to a Tutorial, and collection of Examples, the documentation for this project also includes An Overview of the DBus Protocol

License: MIT

Usage Example

#!/usr/bin/env python

from twisted.internet import reactor, defer
from txdbus import error, client

@defer.inlineCallbacks
def show_desktop_notification():
    '''
    Displays "Hello World!" in a desktop notification window for 3 seconds
    '''
    con = yield client.connect(reactor, 'session')

    notifier = yield con.getRemoteObject('org.freedesktop.Notifications',
                                         '/org/freedesktop/Notifications')

    nid = yield notifier.callRemote('Notify',
                                    'Example Application', 
                                    0,
                                    '',
                                    'Tx DBus Example',
                                    'Hello World!',
                                    [], dict(),
                                    3000)

    reactor.stop()

reactor.callWhenRunning(show_desktop_notification)
reactor.run()
Something went wrong with that request. Please try again.