Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support freezing an object on unpickling by default #175

Open
MatthieuDartiailh opened this issue Aug 22, 2022 · 0 comments
Open

Support freezing an object on unpickling by default #175

MatthieuDartiailh opened this issue Aug 22, 2022 · 0 comments

Comments

@MatthieuDartiailh
Copy link
Member

Currently the default pickling implementation will not produce a frozen object after unpickling if the pickled object is frozen.

This means it is hard to "guarantee" a particular class instance is frozen (by freezing it in __init__). We could store whether the object is frozen or not in the pickle to be able to freeze it in the default setstate method.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant