pickle with constant filesize

Warren Postma embed at geocities.com
Wed May 17 15:01:44 EDT 2000

I would make your own wrapper class for Pickle, called Fickle, and I would
basically build a guestimate of average size of a pickled object, and then
have to live with when my guestimate is wrong, since any limit you choose
become wrong if you put enough data into it.

Rather than that, why not consider using the struct or xstruct modules to
pack your data into fixed binary structures, since that is more realistic
than hoping that your arbitrary-pickled-object will always fit in a certain
size or less?


More information about the Python-list mailing list