[avahi] browsing without event loop ?
Lennart Poettering
lennart at poettering.net
Mon Sep 3 06:59:36 PDT 2007
On Thu, 30.08.07 10:37, Olivier (o.r-d at laposte.net) wrote:
> Hei,
> I am trying to write a python avahi client. I want to get the name
> of machines publising a given service but I would like to AVOID
> using the gtk og qt loop. Is there a way to do that ?
You need some kind of event loop to process events coming from the
Avahi server. It may be any event loop implementation that dbus-python
supports.
Why would you want to avoid running an event loop anyway?
> I have the browse.py example working. Seems that I also made it work
> with a qt loop(even if I need the dbus.glib import). I am writing a
> small xmrpcserver and I only want to check for available services
> once in a while in another thread.
Hmm? Once in a while? Browsing for services is intended to be a long
running operation. Nothing you do in a "one-shot way". That would be
a waste of resources.
Lennart
--
Lennart Poettering Red Hat, Inc.
lennart [at] poettering [dot] net ICQ# 11060553
http://0pointer.net/lennart/ GnuPG 0x1A015CC4
More information about the avahi
mailing list