Skip to content

chore: no warning if array.target_shard_size_bytes is set with shards="auto"#3883

Open
ilan-gold wants to merge 4 commits intozarr-developers:mainfrom
ilan-gold:ig/no_shard_target_warning
Open

chore: no warning if array.target_shard_size_bytes is set with shards="auto"#3883
ilan-gold wants to merge 4 commits intozarr-developers:mainfrom
ilan-gold:ig/no_shard_target_warning

Conversation

@ilan-gold
Copy link
Copy Markdown
Contributor

@ilan-gold ilan-gold commented Apr 8, 2026

I started a zulip discussion here and I feel like the following PR is reasonable. Using sharding simply to make file systems more performant while viewing the subchunks as the real "units" seems to be a nice use-case and if you opt-in to "auto" with a target size, maybe you shouldn't get a warning?

We could in theory also document the strategy of "pack chunks in equally along all dimensions" but is there really any appetite to change that? That stands in contrast to the current "auto" behavior (without a target size) of 2 chunks per dimension in the shard, which does seems like the sort of thing that could change.

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)

@github-actions github-actions bot added the needs release notes Automatically applied to PRs which haven't added release notes label Apr 8, 2026
@github-actions github-actions bot removed the needs release notes Automatically applied to PRs which haven't added release notes label Apr 8, 2026
@ilan-gold ilan-gold changed the title chore: no warning if target shard size is set with auto chore: no warning if array.target_shard_size_bytes is set with shards="auto" Apr 8, 2026
@codecov
Copy link
Copy Markdown

codecov bot commented Apr 8, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 92.98%. Comparing base (9681cf9) to head (e4b52fb).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3883   +/-   ##
=======================================
  Coverage   92.98%   92.98%           
=======================================
  Files          87       87           
  Lines       11246    11247    +1     
=======================================
+ Hits        10457    10458    +1     
  Misses        789      789           
Files with missing lines Coverage Δ
src/zarr/core/chunk_grids.py 96.27% <100.00%> (+0.01%) ⬆️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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.

1 participant