bcdev / nc2zarr

A Python tool that converts NetCDF files to Zarr format
MIT License
9 stars 3 forks source link

Appending unnecessarily requires a coordinate variable #27

Closed forman closed 3 years ago

forman commented 3 years ago

With

input:
  paths: ...
  multi_file: false

output:
  path: ...
  append: true
  append_dim: "sounding_dim"

nc2zarr fails for existing dimension "sounding_dim" but missing (coordinate) variable "sounding_dim" with

Error: Missing (coordinate) variable "sounding_dim" for dimension "sounding_dim".

However, appending datasets to existing Zarrs does not require a (coordinate) variable with same name.

The reason for this error is that input/concat_dim, if not given, is set to output/append_dim regardless of the value of input/multi_file.