[PyQt] PyQt4 dbus mainloop assertion error
Ingmar Steen
iksteen at gmail.com
Wed Apr 25 15:44:43 BST 2007
Hi,
I'm trying to use the new PyQt4 dbus mainloop, but it crashes with an
assertion error when I try to get an object from the bus. I'm using Sip 4.6,
PyQt4.2, Qt 4.2.3, Python 2.5.1, DBus 1.0.2 and dbus-python 0.80.1. Am I
doing something fundamentally insane or wrong?
If I remove the QDBusQtMainLoop(set_as_default=True) line, it works just
fine. The assertion also happens if app.exec_() and get the bus object from
a QTimer event.
Anybody got any ideas?
Ingmar
Here's the sample app:
from PyQt4 import QtCore
from dbus.mainloop.qt import DBusQtMainLoop
import dbus, sys
app = QtCore.QCoreApplication(sys.argv)
DBusQtMainLoop(set_as_default = True)
print 'getting bus'; bus = dbus.SystemBus()
print 'getting obj'; obj = bus.get_object('org.bluez', '/org/bluez')
print 'done'
And here's the output:
$ python test.py
getting bus
getting obj
10739: assertion failed "!(connection)->have_connection_lock" file "
dbus-connection.c" line 3973 function dbus_connection_get_dispatch_status
/usr/lib/libdbus-1.so.3 [0xb7683cde]
/usr/lib/libdbus-1.so.3 [0xb76830c7]
/usr/lib/libdbus-1.so.3 [0xb76777b7]
/usr/lib/libdbus-1.so.3(dbus_connection_get_dispatch_status+0x8f)
[0xb76547ef]
/usr/lib/python2.5/site-packages/dbus/mainloop/qt.so [0xb76a5bd7]
/usr/lib/libdbus-1.so.3 [0xb764e9b5]
/usr/lib/libdbus-1.so.3 [0xb7672208]
/usr/lib/libdbus-1.so.3 [0xb76738c8]
/usr/lib/libdbus-1.so.3 [0xb7673fc2]
/usr/lib/libdbus-1.so.3 [0xb7671ab4]
/usr/lib/libdbus-1.so.3 [0xb7653850]
/usr/lib/libdbus-1.so.3 [0xb76570a0]
/usr/lib/libdbus-1.so.3(dbus_pending_call_block+0x5f) [0xb7669a4f]
/usr/lib/python2.5/site-packages/_dbus_bindings.so [0xb76c0f5c]
/usr/lib/libpython2.5.so.1.0(PyEval_EvalFrameEx+0x5b98) [0xb7eeb4d8]
/usr/lib/libpython2.5.so.1.0(PyEval_EvalFrameEx+0x6098) [0xb7eeb9d8]
/usr/lib/libpython2.5.so.1.0(PyEval_EvalCodeEx+0x793) [0xb7eecac3]
/usr/lib/libpython2.5.so.1.0 [0xb7e8b087]
/usr/lib/libpython2.5.so.1.0(PyObject_Call+0x37) [0xb7e69557]
/usr/lib/libpython2.5.so.1.0 [0xb7e70d02]
/usr/lib/libpython2.5.so.1.0(PyObject_Call+0x37) [0xb7e69557]
/usr/lib/libpython2.5.so.1.0 [0xb7e71254]
/usr/lib/libpython2.5.so.1.0(PyObject_Call+0x37) [0xb7e69557]
/usr/lib/libpython2.5.so.1.0(PyEval_EvalFrameEx+0x1383) [0xb7ee6cc3]
/usr/lib/libpython2.5.so.1.0(PyEval_EvalCodeEx+0x793) [0xb7eecac3]
/usr/lib/libpython2.5.so.1.0 [0xb7e8b087]
/usr/lib/libpython2.5.so.1.0(PyObject_Call+0x37) [0xb7e69557]
/usr/lib/libpython2.5.so.1.0 [0xb7e70d02]
/usr/lib/libpython2.5.so.1.0(PyObject_Call+0x37) [0xb7e69557]
/usr/lib/libpython2.5.so.1.0(PyEval_CallObjectWithKeywords+0x7b)
[0xb7ee4c3b]
/usr/lib/libpython2.5.so.1.0(PyInstance_New+0x7a) [0xb7e748aa]
/usr/lib/libpython2.5.so.1.0(PyObject_Call+0x37) [0xb7e69557]
/usr/lib/libpython2.5.so.1.0(PyEval_EvalFrameEx+0x1383) [0xb7ee6cc3]
/usr/lib/libpython2.5.so.1.0(PyEval_EvalCodeEx+0x793) [0xb7eecac3]
/usr/lib/libpython2.5.so.1.0(PyEval_EvalFrameEx+0x5076) [0xb7eea9b6]
/usr/lib/libpython2.5.so.1.0(PyEval_EvalCodeEx+0x793) [0xb7eecac3]
/usr/lib/libpython2.5.so.1.0(PyEval_EvalCode+0x55) [0xb7eecb35]
/usr/lib/libpython2.5.so.1.0(PyRun_FileExFlags+0xb4) [0xb7f0eec4]
/usr/lib/libpython2.5.so.1.0(PyRun_SimpleFileExFlags+0x1a6) [0xb7f0f1b6]
/usr/lib/libpython2.5.so.1.0(PyRun_AnyFileExFlags+0x7a) [0xb7f0f49a]
/usr/lib/libpython2.5.so.1.0(Py_Main+0xaac) [0xb7f189cc]
python(main+0x32) [0x8048592]
/lib/libc.so.6(__libc_start_main+0xd8) [0xb7cec7c8]
python [0x80484d1]
Aborted
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20070425/47204755/attachment.html
More information about the PyQt
mailing list