-
-
Notifications
You must be signed in to change notification settings - Fork 181
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
Pickling fails for immutable objects that occur in recursive structures #458
Comments
@anivegesana: I'm really hesitant to put out a new release that removes functionality, however we are at that point after your PR #443. What are your plans for this issue? I may have to roll back #443, or try to fix this issue, before I put out the next release. I've been delaying it in hopes this gets resolved. Essentially, it's my fault that I didn't catch you'd removed functionality in #443. However, let me know what your plans are with addressing this, or if I need to do it. |
I was unable to find any significant cases where cloudpickle's approach (break cycles in the functions) fails. The only two cases that their approach fails are ones where the I guess I only need to know if it is fine to exclude these two rarer edge cases so that we can adopt this simpler solution. This, a complete solution, or not making any new changes will not remove functionality since this feature didn't work before #443. The only changes of a more complete solution would be reimplementations of The implementation of the simpler solution is at #461. |
sounds like a good plan, thanks for the quick follow-up |
@anivegesana: What do you want to do with this issue in light of #461 and #448? |
I think we can close it. Although there are some objects that cannot be handled by the PR, a custom |
Minimal failure case:
g.__closure__
containsg
, but not directly. Currently,save_cell
only breaks cycles that directly contain the function, not collections or objects that contain the function.CloudPickle's solution of breaking the cycles within functions as opposed to within cells (like dill does) may be undesirable in some situations:
Therefore, a more dynamic cycle breaking mechanism would be preferred, but tradeoffs of each method should be deliberated.
Another example:
uqfoundation/mystic@f6f71f5
The text was updated successfully, but these errors were encountered: