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

Serialize/ deserialize with cattrs #40

Open
paiforsyth opened this issue Apr 30, 2022 · 1 comment
Open

Serialize/ deserialize with cattrs #40

paiforsyth opened this issue Apr 30, 2022 · 1 comment
Labels
good first issue Good for newcomers

Comments

@paiforsyth
Copy link
Contributor

Cattrs (https://pypi.org/project/cattrs/) is a powerful library for automatic serialisation/ deserialisation of hierarchical data. It seems to me that it could be valuable to use it to implement the various to_json methods (for example https://github.com/carbonplan/xarray-schema/blob/2c56d6ad2d4650ab06b09383a3cdd0bea0988ed7/xarray_schema/dataset.py#L70).

@jhamman
Copy link
Contributor

jhamman commented Sep 14, 2022

Thanks @paiforsyth for the suggestion. I'd love to see a proof of concept using cattrs if you (or anyone else) has time.

@jhamman jhamman added the good first issue Good for newcomers label Sep 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants