On Thu, Mar 31, 2005 at 02:47:22PM +0300, Nikos Kouremenos wrote: > On Thu, 31 Mar 2005 13:37:06 +0200, Antoon Pardon > <[EMAIL PROTECTED]> wrote: > > > > That is the error I get. > > > > First some background. > > > > http://www.pygtk.org/pygtk2reference/gdk-functions.html > > > > In the entry gtk.gdk.threads_init I read the following: > > > > | PyGTK does not release the GIL when calling a GTK or GDK function. > > | Also it does not acquire the GDK global lock (GGL). This means that, > > | in effect, Python threads can use the GIL alone to serialize access to > > | the GTK and GDK libraries. Of course, if there are non-Python threads > > | calling GTK or GDK functions the GGL must be used. > > > > However when I remove the gtk.threads_leave() and gtk.threads_enter() > > calls from my program after sometime the program crashes and I get the > > following message: > > > > Xlib: unexpected async reply (sequence 0x10e6b)! > > > > Now I'm wondering. Is this a bug in pygtk or is the documentation not > > accurate? I'm using python 2.3.5 and pygtk 2.6.1 on a Debian testing > > machine. > > Threads can be a pain in the ass. If you handling gui then you should > not remove threads_enter()/leave().
So, according to you this is a documentation problem? -- Antoon Pardon _______________________________________________ pygtk mailing list pygtk@daa.com.au http://www.daa.com.au/mailman/listinfo/pygtk Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/