Skip to content

chore!: remove the ignored Zarr-Python 2 parameters - #4522

Open
maxrjones wants to merge 2 commits into
zarr-developers:mainfrom
maxrjones:deprecate/ignored-v2-kwargs
Open

maxrjones wants to merge 2 commits into
zarr-developers:mainfrom
maxrjones:deprecate/ignored-v2-kwargs

Conversation

@maxrjones

Copy link
Copy Markdown
Member

Summary

This PR implements the first step of the plan for #3976, by starting a deprecation cycle for all the Zarr-Python 2 era parameters that have no impact on the behavior in Zarr-Python 3.

For reviewers

It would be good to get an approval on the plan. Note I think this is mutually exclusive with #3215, which instead implements cache_attrs.

I would be tempted to shorten the standard cycle from warning to removal for these to 3+ months rather than 6+months, given we can be sure they weren't succesfully used and their inclusion can be harmfully confusing (in particular the read_only unimplemented parameter).

Author attestation

  • I am a human, these are my changes, and I have reviewed and understood every change and can explain why each is correct.

TODO

  • Add unit tests and/or doctests in docstrings
  • Add docstrings and API docs for any new/modified user-facing classes and functions
  • New/modified features documented in docs/user-guide/*.md
  • Changes documented as a new file in changes/
  • GitHub Actions have all passed
  • Test coverage is 100% (Codecov passes)

`synchronizer`, `chunk_store`, `cache_metadata`, `cache_attrs`,
`object_codec`, `read_only` and `meta_array` are accepted by `create`,
`group` and `open_group` (and by everything that wraps them, such as
`zeros`) but have never done anything in Zarr-Python 3. Passing one
used to emit a `ZarrRuntimeWarning` saying "not yet implemented", which
read as a promise to implement it.

Emit a `ZarrDeprecationWarning` instead, saying the argument is ignored
and will be removed in a release after April 2027, and say the same in
the docstrings and the v3 migration guide. Calls that do not pass these
arguments are unaffected.

First step of the plan for zarr-developers#3976.
@codecov

codecov Bot commented Oct 17, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 94.71%. Comparing base (bd0dc84) to head (a11f795).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #4522   +/-   ##
=======================================
  Coverage   94.71%   94.71%           
=======================================
  Files          94       94           
  Lines       13663    13663           
=======================================
  Hits        12941    12941           
  Misses        722      722           
Files with missing lines Coverage Δ
src/zarr/api/asynchronous.py 96.46% <100.00%> (ø)
src/zarr/api/synchronous.py 95.77% <ø> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@d-v-b

d-v-b commented Oct 17, 2026

Copy link
Copy Markdown
Contributor

i love this, thank you max!

This branch has not been deployed

No deployments
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.

2 participants