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

backwards deserialization compatibility #675

Merged
merged 2 commits into from Apr 4, 2023

Conversation

ijpulidos
Copy link
Contributor

Description

This catches a KeyError when deserializing which prevents raising an error when deserializing objects from previous versions (0.21.4 or lower). It does so by showing a warning to the user.

Resolves #618

Todos

  • Implement feature / fix bug
  • Add tests
  • Update documentation as needed
  • Update changelog to summarize changes in behavior, enhancements, and bugfixes implemented in this PR

Status

  • Ready to go

Changelog message

Backwards compatibility when deserializing netcdf (`.nc`) files from previous versions (<=0.21.4).

@ijpulidos ijpulidos added this to the 0.22.0 milestone Apr 4, 2023
@mikemhenry
Copy link
Contributor

This should work, the warning is good. A future TODO could be to make sure that error doesn't get raised in our serialization tests, and have a test where we assert this error gets raised, but this is good for now.

@mikemhenry
Copy link
Contributor

I think we should change the changelog to:
Warn users when deserializing netcdf (.nc) files from previous versions (<=0.21.4). KeyErrors will be treated as warnings when deserializing netcdf files

@mikemhenry mikemhenry merged commit 3bfc434 into main Apr 4, 2023
14 checks passed
@mikemhenry mikemhenry deleted the 618-serialization-compatibility branch April 4, 2023 19:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants