Zarr version
3.1.5
Numcodecs version
0.16.5
Python Version
3.12
Operating System
Mac
Installation
pip
Description
In zarr 3, shapes can no longer be numpy int types. This used to work in zarr 2.
Steps to reproduce
# /// script
# requires-python = ">=3.11"
# dependencies = [
# "zarr@git+https://github.com/zarr-developers/zarr-python.git@main",
# ]
# ///
#
# This script automatically imports the development branch of zarr to check for issues
import zarr
import numpy as np
a = np.ones(2, dtype=int)
zarr.create_array("test", shape=(int(a.max())), dtype=int) # works
zarr.create_array("test2", shape=(a.max()),
dtype=int) # TypeError: Expected an integer or an iterable of integers. Got 1 instead.
Additional output
No response
Zarr version
3.1.5
Numcodecs version
0.16.5
Python Version
3.12
Operating System
Mac
Installation
pip
Description
In zarr 3, shapes can no longer be numpy int types. This used to work in zarr 2.
Steps to reproduce
Additional output
No response