Ryan Stuart <ryan.stuart...@gmail.com> writes: > I think that is a pretty accurate summary. In fact, the article even > says that. So, just to iterate its point, if you are using > non-blocking Queues to communicate to these threads, then you just > have a communicating event loop. Given that Queues work perfectly with > with processes as well, what is the point of using a thread?
What do you mean about Queues working with processes? I meant Queue.Queue. There is multiprocessing.Queue but that's much less capable, and it uses cumbersome IPC like pipes or sockets instead of a lighter weight lock. Threads can also share read-only data and you can pass arbitrary objects (such as code callables that you want the other thread to execute--this is quite useful) through Queue.Queue. I don't think you can do that with the multiprocessing module. -- https://mail.python.org/mailman/listinfo/python-list