Skip to content

Replace deprecated zarr_version argument with zarr_format #107

Description

@freds-dev

Describe the bug

zappend emits a FutureWarning when it creates a new Zarr target dataset:

FutureWarning: zarr_version is deprecated, use zarr_format

The append still succeeds, but zappend uses the deprecated zarr_version argument when calling xarray’s Dataset.to_zarr().

To Reproduce

Run a zappend operation that creates an initial target Zarr cube, for example:

import xarray as xr
from zappend.api import zappend

ds = xr.Dataset({"value": ("time", [1])}, coords={"time": [0]})

zappend(
    [ds],
    target_dir="./target.zarr",
    temp_dir="./temporary",
    append_dim="time",
    append_step="+",
)

Expected behavior

zappend should create the Zarr target without a deprecation warning.

The call in zappend/processor.py should use:

zarr_format=ctx.config.zarr_version,

instead of:

zarr_version=ctx.config.zarr_version,

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions