-
Notifications
You must be signed in to change notification settings - Fork 121
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
Make item pickle smaller #1285
Make item pickle smaller #1285
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1285 +/- ##
==========================================
+ Coverage 91.11% 91.12% +0.01%
==========================================
Files 51 51
Lines 6986 6994 +8
Branches 999 1001 +2
==========================================
+ Hits 6365 6373 +8
Misses 444 444
Partials 177 177 ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The only limitation I can see is that if you have a resolved target object on your link, it will not be resolved with you roundtrip it to pickle and back.
This feels like the right behavior -- you (theoretically) can always re-resolve the object later. I'm ok with this change, but I'm not the target user here -- is there anyone that uses pystac in Dask-land that can verify that things are better w/ this fix. Maybe @TomAugspurger?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Won't have time to test this out for real, but in general I've found len(pickle.dumps(obj))
to be a good enough test for fixes like this.
Related Issue(s):
Description:
Not totally sure if this is a good idea, but I figured a PR would be a good place to hash that out. The only limitation I can see is that if you have a resolved target object on your link, it will not be resolved with you roundtrip it to pickle and back.
PR Checklist:
pre-commit
hooks pass locallyscripts/test
)