feat/codec classes in array config#3892
Open
d-v-b wants to merge 14 commits intozarr-developers:mainfrom
Open
Conversation
…at/codec-classes-in-array-config
…/zarr-python into feat/codec-classes-in-array-config
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3892 +/- ##
==========================================
- Coverage 92.98% 92.86% -0.13%
==========================================
Files 87 87
Lines 11246 11335 +89
==========================================
+ Hits 10457 10526 +69
- Misses 789 809 +20
🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR makes the changes necessary for adding the following features:
We get these features by putting the codec classes and codec pipeline class in the array config, and adding these as explicit parameters to all the inner routines that were previously relying on the global config.
for context, our inner routines should never be relying on the global config. It's a mutable global variable that should only be used to creating default values at the boundary of zarr-python. Internally, each function should declare what it needs in its signature, without implicitly relying on the global config. These changes move us in that direction.
I am sensitive to this because I have been working on codecs / codec pipelines recently and the developer experience (changing things through the global config) is terrible. we need to fix this.
here's are some motivating example from the tests: