object pickling

Eyal Lotem gnupeaker at yahoo.com
Sat Jul 24 18:51:40 EDT 2004


--- "max(01)*" <max at fisso.casa> wrote:
> also i would like to know: why in the world would
> anyone want to pickle 
> a builtin function, as the documentation says it's
> possible?

In PyInvoke (http://pybuild.sf.net/pyinvoke.html), I
use pickling of all types of objects as the basis for
the pyinvoke protocol, allowing all sorts of funky
stuff :-)

Actually, in order to invoke arbitrary methods at the
server-side with minimum fuss, I simply send a pickled
tuple containing the function to run, the arguments
and the keywords, which is a very convinient way to
denote a function reference at the server-side. 
Ofcourse I use this only on functions that really
exist at the server-side as someone else said: it is
pickled by reference.

I still think PyInvoke is a really nice demonstration
of what can be done with Python's dynamic power and
the powerful pickle module. 



		
__________________________________
Do you Yahoo!?
Yahoo! Mail - 50x more storage than other providers!
http://promotions.yahoo.com/new_mail



More information about the Python-list mailing list