Skip to content

Commit 46e21df

Browse files
authored
Merge branch 'main' into perf-write-shard
2 parents 9b66073 + 62551c7 commit 46e21df

File tree

210 files changed

+22798
-13255
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

210 files changed

+22798
-13255
lines changed

.github/CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
Contributing
22
============
33

4-
Please see the [project documentation](https://zarr.readthedocs.io/en/stable/contributing.html) for information about contributing to Zarr.
4+
Please see the [project documentation](https://zarr.readthedocs.io/en/stable/developers/contributing.html) for information about contributing to Zarr.

.github/ISSUE_TEMPLATE/bug_report.yml

Lines changed: 16 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,22 @@ body:
5757
id: reproduce
5858
attributes:
5959
label: Steps to reproduce
60-
description: Minimal, reproducible code sample, a copy-pastable example if possible.
60+
description: Minimal, reproducible code sample. Must list dependencies in [inline script metadata](https://packaging.python.org/en/latest/specifications/inline-script-metadata/#example). When put in a file named `issue.py` calling `uv run issue.py` should show the issue.
61+
value: |
62+
```python
63+
# /// script
64+
# requires-python = ">=3.11"
65+
# dependencies = [
66+
# "zarr@git+https://github.com/zarr-developers/zarr-python.git@main",
67+
# ]
68+
# ///
69+
#
70+
# This script automatically imports the development branch of zarr to check for issues
71+
72+
import zarr
73+
# your reproducer code
74+
# zarr.print_debug_info()
75+
```
6176
validations:
6277
required: true
6378
- type: textarea
Lines changed: 59 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,59 @@
1+
---
2+
name: Zarr-Python release checklist
3+
about: Checklist for a new Zarr-Python release. [For project maintainers only!]
4+
title: Release Zarr-Python vX.Y.Z
5+
labels: release-checklist
6+
assignees: ''
7+
8+
---
9+
10+
**Release**: [v3.x.x](https://github.com/zarr-developers/zarr-python/milestones/?)
11+
**Scheduled Date**: 20YY/MM/DD
12+
13+
**Priority PRs/issues to complete prior to release**
14+
15+
- [ ] Priority pull request #X
16+
17+
**Before release**:
18+
19+
- [ ] Make sure the release branch (e.g., `3.1.x`) is up to date with any backports.
20+
- [ ] Make sure that all pull requests which will be included in the release have been properly documented as changelog files in the [`changes/` directory](https://github.com/zarr-developers/zarr-python/tree/main/changes).
21+
- [ ] Run ``towncrier build --version x.y.z`` to create the changelog, and commit the result to the release branch.
22+
- [ ] Check [SPEC 0](https://scientific-python.org/specs/spec-0000/#support-window) to see if the minimum supported version of Python or NumPy needs bumping.
23+
- [ ] Check to ensure that:
24+
- [ ] Deprecated workarounds/codes/tests are removed. Run `grep "# TODO" **/*.py` to find all potential TODOs.
25+
- [ ] All tests pass in the ["Tests" workflow](https://github.com/zarr-developers/zarr-python/actions/workflows/test.yml).
26+
- [ ] All tests pass in the ["GPU Tests" workflow](https://github.com/zarr-developers/zarr-python/actions/workflows/gpu_test.yml).
27+
- [ ] All tests pass in the ["Hypothesis" workflow](https://github.com/zarr-developers/zarr-python/actions/workflows/hypothesis.yaml).
28+
- [ ] Check that downstream libraries work well (maintainers can make executive decisions about whether all checks are required for this release).
29+
- [ ] numcodecs
30+
- [ ] Xarray (@jhamman @dcherian @TomNicholas)
31+
- Zarr's upstream compatibility is tested via the [Upstream Dev CI worklow](https://github.com/pydata/xarray/actions/workflows/upstream-dev-ci.yaml).
32+
- Click on the most recent workflow and check that the `upstream-dev` job has run and passed. `upstream-dev` is not run on all all workflow runs.
33+
- Check that the expected version of Zarr-Python was tested using the `Version Info` step of the `upstream-dev` job.
34+
- If testing on a branch other than `main` is needed, open a PR modifying https://github.com/pydata/xarray/blob/90ee30943aedba66a37856b2332a41264e288c20/ci/install-upstream-wheels.sh#L56 and add the `run-upstream` label.
35+
- [ ] Titiler.Xarray (@maxrjones)
36+
- [Modify dependencies](https://github.com/developmentseed/titiler/blob/main/src/titiler/xarray/pyproject.toml) for titiler.xarray.
37+
- Modify triggers for running [the test workflow](https://github.com/developmentseed/titiler/blob/61549f2de07b20cca8fb991cfcdc89b23e18ad05/.github/workflows/ci.yml#L5-L7).
38+
- Push the branch to the repository and check for the actions for any failures.
39+
40+
**Release**:
41+
42+
- [ ] Go to https://github.com/zarr-developers/zarr-python/releases.
43+
- [ ] Click "Draft a new release".
44+
- [ ] Choose a version number prefixed with a `v` (e.g. `v0.0.0`). For pre-releases, include the appropriate suffix (e.g. `v0.0.0a1` or `v0.0.0rc2`).
45+
- [ ] Set the target branch to the release branch (e.g., `3.1.x`)
46+
- [ ] Set the description of the release to: `See release notes https://zarr.readthedocs.io/en/stable/release-notes.html#release-0-0-0`, replacing the correct version numbers. For pre-release versions, the URL should omit the pre-release suffix, e.g. "a1" or "rc1".
47+
- [ ] Click on "Generate release notes" to auto-fill the description.
48+
- [ ] Make a release by clicking the 'Publish Release' button, this will automatically create a tag too.
49+
- [ ] Verify that release workflows succeeded.
50+
- [ ] The latest version is correct on [PyPI](https://pypi.org/project/zarr/).
51+
- [ ] The stable version is correct on [ReadTheDocs](https://zarr.readthedocs.io/en/stable/).
52+
53+
**After release**:
54+
55+
- [ ] Review and merge the pull request on the conda-forge [zarr-feedstock](https://github.com/conda-forge/zarr-feedstock) that will be automatically generated.
56+
57+
---
58+
59+
- [ ] Party :tada:

.github/codecov.yml

Lines changed: 0 additions & 15 deletions
This file was deleted.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: Check changelog entries
2+
3+
on:
4+
pull_request:
5+
6+
jobs:
7+
check-changelogs:
8+
name: Check changelog entries
9+
runs-on: ubuntu-latest
10+
11+
steps:
12+
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
13+
14+
- name: Install uv
15+
uses: astral-sh/setup-uv@b75a909f75acd358c2196fb9a5f1299a9a8868a4 # v6.7.0
16+
17+
- name: Check changelog entries
18+
run: uv run --no-sync python ci/check_changelog_entries.py

.github/workflows/gpu_test.yml

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,9 @@ name: GPU Test
55

66
on:
77
push:
8-
branches: [ main ]
8+
branches: [ main, 3.1.x ]
99
pull_request:
10-
branches: [ main ]
10+
branches: [ main, 3.1.x ]
1111
workflow_dispatch:
1212

1313
env:
@@ -25,11 +25,13 @@ jobs:
2525
strategy:
2626
matrix:
2727
python-version: ['3.11']
28-
numpy-version: ['2.1']
28+
numpy-version: ['2.2']
2929
dependency-set: ["minimal"]
3030

3131
steps:
32-
- uses: actions/checkout@v4
32+
- uses: actions/checkout@v5
33+
with:
34+
fetch-depth: 0 # grab all branches and tags
3335
# - name: cuda-toolkit
3436
# uses: Jimver/[email protected]
3537
# id: cuda-toolkit
@@ -49,7 +51,7 @@ jobs:
4951
echo $LD_LIBRARY_PATH
5052
nvcc -V
5153
- name: Set up Python
52-
uses: actions/setup-python@v5
54+
uses: actions/setup-python@v6
5355
with:
5456
python-version: ${{ matrix.python-version }}
5557
cache: 'pip'
@@ -63,7 +65,7 @@ jobs:
6365
hatch env run -e gputest.py${{ matrix.python-version }}-${{ matrix.numpy-version }}-${{ matrix.dependency-set }} list-env
6466
- name: Run Tests
6567
run: |
66-
hatch env run --env gputest.py${{ matrix.python-version }}-${{ matrix.numpy-version }}-${{ matrix.dependency-set }} run-coverage
68+
hatch env run --env gputest.py${{ matrix.python-version }}-${{ matrix.numpy-version }}-${{ matrix.dependency-set }} run-coverage-gpu
6769
6870
- name: Upload coverage
6971
uses: codecov/codecov-action@13ce06bfc6bbe3ecf90edbbf1bc32fe5978ca1d3 # v5.3.1

.github/workflows/hypothesis.yaml

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
11
name: Slow Hypothesis CI
22
on:
33
push:
4-
branches:
5-
- "main"
4+
branches: [main, 3.1.x]
65
pull_request:
7-
branches:
8-
- "main"
6+
branches: [main, 3.1.x]
97
types: [opened, reopened, synchronize, labeled]
108
schedule:
119
- cron: "0 0 * * *" # Daily “At 00:00” UTC
@@ -25,14 +23,21 @@ jobs:
2523

2624
strategy:
2725
matrix:
28-
python-version: ['3.11']
29-
numpy-version: ['2.1']
26+
python-version: ['3.12']
27+
numpy-version: ['2.2']
3028
dependency-set: ["optional"]
3129

3230
steps:
33-
- uses: actions/checkout@v4
31+
- uses: actions/checkout@v5
32+
- name: Set HYPOTHESIS_PROFILE based on trigger
33+
run: |
34+
if [[ "${{ github.event_name }}" == "schedule" || "${{ github.event_name }}" == "workflow_dispatch" ]]; then
35+
echo "HYPOTHESIS_PROFILE=nightly" >> $GITHUB_ENV
36+
else
37+
echo "HYPOTHESIS_PROFILE=ci" >> $GITHUB_ENV
38+
fi
3439
- name: Set up Python
35-
uses: actions/setup-python@v5
40+
uses: actions/setup-python@v6
3641
with:
3742
python-version: ${{ matrix.python-version }}
3843
cache: 'pip'
@@ -58,6 +63,7 @@ jobs:
5863
if: success()
5964
id: status
6065
run: |
66+
echo "Using Hypothesis profile: $HYPOTHESIS_PROFILE"
6167
hatch env run --env test.py${{ matrix.python-version }}-${{ matrix.numpy-version }}-${{ matrix.dependency-set }} run-hypothesis
6268
6369
# explicitly save the cache so it gets updated, also do this even if it fails.
@@ -81,7 +87,7 @@ jobs:
8187
&& steps.status.outcome == 'failure'
8288
&& github.event_name == 'schedule'
8389
&& github.repository_owner == 'zarr-developers'
84-
uses: xarray-contrib/issue-from-pytest-log@v1
90+
uses: scientific-python/issue-from-pytest-log-action@v1
8591
with:
8692
log-path: output-${{ matrix.python-version }}-log.jsonl
8793
issue-title: "Nightly Hypothesis tests failed"

.github/workflows/needs_release_notes.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ jobs:
1111
pull-requests: write
1212
runs-on: ubuntu-latest
1313
steps:
14-
- uses: actions/labeler@8558fd74291d67161a8a78ce36a881fa63b766a9 # v5.0.0
14+
- uses: actions/labeler@634933edcd8ababfe52f92936142cc22ac488b1b # v6.0.1
1515
with:
1616
repo-token: ${{ secrets.GITHUB_TOKEN }}
1717
sync-labels: true
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Nightly Wheels
2+
3+
on:
4+
schedule:
5+
# Run nightly at 2 AM UTC
6+
- cron: '0 2 * * *'
7+
workflow_dispatch:
8+
9+
jobs:
10+
build_and_upload_nightly:
11+
name: Build and upload nightly wheels
12+
runs-on: ubuntu-latest
13+
14+
steps:
15+
- uses: actions/checkout@v5
16+
with:
17+
submodules: true
18+
fetch-depth: 0
19+
20+
- uses: actions/setup-python@v6
21+
name: Install Python
22+
with:
23+
python-version: '3.13'
24+
25+
- name: Install build dependencies
26+
run: |
27+
python -m pip install --upgrade pip
28+
pip install hatch
29+
30+
- name: Build wheel and sdist
31+
run: hatch build
32+
33+
- name: Upload nightly wheels
34+
uses: scientific-python/upload-nightly-action@b36e8c0c10dbcfd2e05bf95f17ef8c14fd708dbf
35+
with:
36+
artifacts_path: dist
37+
anaconda_nightly_upload_token: ${{ secrets.ANACONDA_ORG_UPLOAD_TOKEN }}

.github/workflows/releases.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,12 @@ jobs:
1111
fail-fast: false
1212

1313
steps:
14-
- uses: actions/checkout@v4
14+
- uses: actions/checkout@v5
1515
with:
1616
submodules: true
1717
fetch-depth: 0
1818

19-
- uses: actions/setup-python@v5.2.0
19+
- uses: actions/setup-python@v6
2020
name: Install Python
2121
with:
2222
python-version: '3.11'
@@ -36,7 +36,7 @@ jobs:
3636
needs: [build_artifacts]
3737
runs-on: ubuntu-latest
3838
steps:
39-
- uses: actions/download-artifact@v4
39+
- uses: actions/download-artifact@v5
4040
with:
4141
name: releases
4242
path: dist
@@ -51,11 +51,11 @@ jobs:
5151
runs-on: ubuntu-latest
5252
if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/v')
5353
steps:
54-
- uses: actions/download-artifact@v4
54+
- uses: actions/download-artifact@v5
5555
with:
5656
name: releases
5757
path: dist
58-
- uses: pypa/gh-action-pypi-publish@v1.12.4
58+
- uses: pypa/gh-action-pypi-publish@v1.13.0
5959
with:
6060
user: __token__
6161
password: ${{ secrets.pypi_password }}

0 commit comments

Comments
 (0)