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

Remove compatiblity shims and allow default pickle override through a setting. #52

Merged
merged 4 commits into from Jun 5, 2020

Conversation

charettes
Copy link
Collaborator

@carltongibson I replaced the DEFAULT_PROTOCOL bump by a new setting instead as this bump breaks backward compatibility of __exact lookups since the string representation of pickles changes.

We could have documented it as a backward incompatible change but I feared some folks might blindly upgrade and end up with a database that is a mix of protocol 2 and 3 pickles which would break __exact and friends.

By introducing this new PICKLEFIELD_DEFAULT_PROTOCOL setting it should be possible for users to upgrade to the version they seem for fit for their use case (even > 3) without breaking backward compatibility.

The latter is pending deprecation since it's an alias of the former on
Python 3.
Bumping this value without allowing an override breaks backward compatibility
for lookups such as __exact because the string representation of the pickles
change.
@carltongibson
Copy link

@charettes Thanks for the notification! Works for me. 👍

@charettes charettes merged commit 9100f30 into master Jun 5, 2020
@coveralls
Copy link

Coverage Status

Coverage increased (+0.1%) to 99.038% when pulling 0d84840 on legacy-cleanups into c615d9d on master.

@charettes charettes deleted the legacy-cleanups branch June 18, 2022 20:14
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

Successfully merging this pull request may close these issues.

None yet

3 participants