By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
455,538 Members | 1,293 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 455,538 IT Pros & Developers. It's quick & easy.

enum 0.4.1 not pickle-firendly

P: n/a
ago
I have started using the enum module () , at them moment pickling an
object instance that has an EnumValues assigned to one of its
attributes pickles the full enumeration, this is not efficient. I am
not sure what is the best way around (I do not like the idea of having
to use __getstate__/__setstate__ every time), but I guess that a
EnumValue should not have a reference to an Enum instance. Maybe a
better approach might be to have Enum as a metaclass so that each
EnumValue only references the particular Enum class.

Jul 19 '06 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.