[Tkinter-discuss] TkAqua issue: are threaded Python applications still possible on OS X?

sarah.nason at utoronto.ca sarah.nason at utoronto.ca
Wed Feb 24 18:44:55 CET 2010


For the last few weeks, I've been trying to fix a problem with the OS  
X port of a program I'm working on, PyGraphics; since I've had no  
luck, I'm here in search of your expertise.

PyGraphics is a multithreaded module designed to be imported into and  
used in computer science students' programs. It works fine on Windows  
and Linux, and it used to function on OS X, too - but the release of  
Snow Leopard put an end to that. TkAqua does not permit mainloop() to  
be run on background threads, and since Wing (the IDE of choice for my  
university) is running the application, all threads related to  
PyGraphics are background threads by definition.

Has anyone found any workarounds for this problem? I've looked into  
TkX11, and have recompiled Tcl/Tk with the --disable-aqua and --with-x  
configuration options, but that didn't help. There is a suggestion  
that the version of Python that ships with Snow Leopard doesn't play  
well with that version of Tk, but I've not found much documentation to  
confirm or deny that possibility. Right now, the most viable option  
appears to be rewriting the program to offer an unthreaded version to  
Mac students, but that's just sad.

Any ideas? Thanks in advance!

-- Sarah Nason

More information about the Tkinter-discuss mailing list