[GDBus] Reopening the session bus

Simon McVittie simon.mcvittie at collabora.co.uk
Fri Apr 10 04:16:45 PDT 2015


On 09/04/15 14:19, Ted Gould wrote:
> To work around this we've been putting a weak reference unto the session
> bus, dropping our reference, and then waiting for the weak pointer to
> clear the memory location. Not sure how you'd implement that in Python
> though.

I still prefer the solution I suggested: force the test bus to be at a
specific path (computed at runtime, but constant per run) rather than
using unix:tmpdir=/tmp, so that you can kill and restart it while
keeping the same address.

You could even combine the two: after each test, kill the dbus-daemon,
then wait for the GDBusConnection to signal that it has been disconnected.

-- 
Simon McVittie
Collabora Ltd. <http://www.collabora.com/>


More information about the dbus mailing list