feat(format): read the other attributes when one cannot be read
attrs() read every attribute of an object through extract_attributes_full, so one attribute it could not read (a corrupt or unsupported attribute message, or a heap object it could not locate) failed all of them — the same shape as the huge-object bug, where one 8 KiB attribute hid every attribute on a NetCDF file's root group. - clawhdf5-format: new attribute::extract_attributes_tolerant returns the attributes it could read plus one error per attribute it could not. Errors in the attribute index itself (Attribute Info message, dense heap header, B-tree) still fail, since then it is unknown which attributes exist. extract_attributes_full is unchanged (strict); both share one implementation. - clawhdf5: attrs() on Group/Dataset, MmapGroup/MmapDataset and LazyGroup/LazyDataset leaves an unreadable attribute out (documented), and the new attrs_with_errors() returns the map with the per-attribute errors. A value is either returned complete or not at all. Regression test: one_unreadable_attribute_does_not_hide_the_others (h5py writes 11 dense attributes; one message's version byte is corrupted; before: attrs() failed with InvalidAttributeVersion(127), after: the 10 others come back with their values and one error is reported). Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
This commit is contained in:
@@ -87,7 +87,9 @@ the VDS item, which is marked.
|
||||
- **Dense attributes:** a large attribute stored as a fractal-heap "huge"
|
||||
object makes every attribute on the object fail. This affects real NetCDF
|
||||
files (`issue671.nc`). **Fixed 2026-09-25:** huge and tiny heap objects,
|
||||
and filtered heaps, are read.
|
||||
and filtered heaps, are read; and an attribute that still cannot be read
|
||||
is left out of `attrs()` (reported by `attrs_with_errors()`) instead of
|
||||
failing the others.
|
||||
- **Other readers:**
|
||||
- VL-string datasets are not readable through `File`.
|
||||
- Metadata cache images are not supported.
|
||||
|
||||
Reference in New Issue
Block a user