/srv/irclogs.ubuntu.com/2012/08/13/#ubuntu-nz.txt

=== timfrost is now known as timfrost1
thomilifeless: got a second?03:24
lifelesssure03:32
thomilifeless: some kind folk in #python tell me that there's something in testtools that should let me relinquish control mid-way through a test to the glib main loop, then complete my test when some glib signal is fired. Possibly something to do with AsynchronousDeferredRunTest, but I'm struggling to find any examples of that that make sense to me.03:34
thomiIt seems I need to glue the glib main loop into the ADRT _run_core somehow?03:35
lifelesssure03:35
lifelessuhm03:35
lifelessyou can do that03:35
lifelessbut unlike twisted glib supports nested loops03:35
lifelessso you can be a lot simpler03:35
lifelesshook up your glib signal to the glib stop event03:36
lifelessand just call glib.mainloop() from your test03:36
lifelessit will exit when the stop/exit event tells it to stop03:36
thomihmmmmm03:37
lifelessthe ADRT is used because there are fugly things needed to work with the twisted reactor03:37
lifelessand to add timeout support03:37
lifelesswhat you'd need to do to do glib support *in that manner* is to create a new ADRT specialised for glib.03:37
lifelessit will be very different code in some parts03:38
thomiyeah... cool - thanks, I'll try that.03:38
lifelessI'd try using glib directly first03:39
lifelessget that working, then look at hauling it out sideways.03:39
lifelesstimeouts are easy with glib - just setup a glib clock event to call loop.stop or whatever (I'm making up the names becaues I haven't looked at glib code in a couple of years)03:40
thomilifeless: yeah... that sounds sensible03:54
chiltsmorning19:34
ibeardsleemorning19:53
ajmitchmorning20:02
Atamiramorning20:30

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!