This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author alexandre.vassalotti
Recipients alexandre.vassalotti, amaury.forgeotdarc, jnoller
Date 2008-08-15.04:09:37
SpamBayes Score 0.00020824958
Marked as misclassified No
Message-id <1218773379.16.0.303666881343.issue3385@psf.upfronthosting.co.za>
In-reply-to
Content
I ran into a few problems while trying to fix this issue. First, does
someone know how to add class attributes on extension types? It sounds
like I will need either some tp_dict hacking or a Pickler subclass.

Second, which methods of Pickler should be made public? I know
save_reduce() is needed, but would it be worthwhile to expose more? In
the recipe Amaury linked (which abuses Pickler IMHO), save_global(),
save_dict(), write() and memoize() are used. Exposing all save_* methods
is out of question for now as none were written to be used standalone.

Third, should Pickler allows pickling support for built-in types (e.g.,
int, dict, tuple, etc) to be overridden? Currently, pickle.py allows it.
However, I am not sure if it is a good idea to copy this "feature" in
_pickle.c.
History
Date User Action Args
2008-08-15 04:09:39alexandre.vassalottisetrecipients: + alexandre.vassalotti, amaury.forgeotdarc, jnoller
2008-08-15 04:09:39alexandre.vassalottisetmessageid: <1218773379.16.0.303666881343.issue3385@psf.upfronthosting.co.za>
2008-08-15 04:09:38alexandre.vassalottilinkissue3385 messages
2008-08-15 04:09:37alexandre.vassalotticreate