[Baypiggies] how to IPC with python on linux?

Rami Chowdhury rami.chowdhury at gmail.com
Fri Dec 3 01:33:30 CET 2010


How about D-BUS, or some other more general IPC solution? Python's got good DBUS bindings IIRC...

On Dec 2, 2010, at 22:47 , Ian Zimmerman wrote:

> 
> Brian> The easy answer is to use the multiprocessing package:
> Brian> http://docs.python.org/library/multiprocessing.html
> 
> Heh.  I just tried to use multiprocessing for the first time for hgit,
> my hg-to-git conversion program[1].  My rationale was probably similar
> to that of jim's group or many other people, i.e. threads are a pain,
> there's the GIL, etc.  But in the end I gave up and used threads.  The
> trouble was that everything I sent over the IPC channel had to be
> picklable, and worse, the target of a multiprocessing.Process cannot be
> any callable (as it can for thrading.Thread), but only a module-level
> function, i.e. no closures or instance methods.  These requirements
> together would pretty much force me to make all the interesting data
> global.
> 
> [1] http://pypi.python.org/pypi/hgit/20101202
> 
> -- 
> Ian Zimmerman <itz at buug.org>
> gpg public key: 1024D/C6FF61AD 
> fingerprint: 66DC D68F 5C1B 4D71 2EE5  BD03 8A00 786C C6FF 61AD
> Ham is for reading, not for eating.
> _______________________________________________
> Baypiggies mailing list
> Baypiggies at python.org
> To change your subscription options or unsubscribe:
> http://mail.python.org/mailman/listinfo/baypiggies

-------------
Rami Chowdhury
"Never assume malice when stupidity will suffice." -- Hanlon's Razor
+44-7581-430-517 / +88-0189-245544 / +1-408-597-7068 






More information about the Baypiggies mailing list