Styxis
Company
Knowledge

Keep empty Xarray selections distinct from backend execution failures

An empty axis can be a valid result. Keep execution errors separate from the resulting axis structure.

A structure survives an empty request

A requested empty array and an execution failure are different states. Derive the expected shape from the selection and compare it separately from completion status. Empty observation periods need not be failures, but a failure must not be relabeled as an empty observation. A shape audit of completed results lets Truthound express the admission condition for an empty structure. [1, 2, 3]

A hard error, not silent loss

Xarray #11625 reports multidimensional empty isel selections raising errors with h5netcdf and scipy backends. It explicitly distinguishes hard errors from silent wrong results. The unaffected 1-dimensional case does not establish support for every multi-axis combination. [1]

Record completion first

Record selection lists per axis, the expected shape, completion status, and actual disk-backed and in-memory shapes. Preserve exceptions as failures while testing a verified backend or explicit empty structure. Extract shapes only from completed results and retain the selection semantics and backend version. [1, 3]

0x2 versus an axisless empty vector

In an illustrative 4×5 grid, x=[] and y=[1,3] require x length 0 and y length 2, giving shape 0x2. An actual completed shape of 0x2 passes. The axisless empty-vector signature 0 fails. Do not manufacture a normal empty shape for a run that ended in an exception. [1, 3]

The scope of a shape audit

ColumnPairValidator in Truthound Python SDK 3.3.2 compares actual_shape and requested_shape extracted by the operator from completed results. Check execution-failure flags and axis names separately. Core does not catch backend exceptions and reconstruct arrays; a matching empty shape does not establish coordinate names or values. [1, 2, 3]

Retain axis meaning when changing paths

Compare a small in-memory selection with a verified backend or explicitly constructed empty-axis path. Retain the axis roles when changing paths. Tasks using only 1-dimensional selections or unaffected backends should not inherit the report’s multidimensional failure automatically. [1, 3]

Application conditions

Extract shapes only from completed results, retaining exceptions, per-axis selections, and backend versions separately.

Alternatives

Compare a small in-memory path, a verified backend, and an explicit empty structure.

Limitations

  • Shape agreement does not establish coordinate names or values, and the validator does not repair backend exceptions.

Evidence

Event checked
Subject checked
Modified