Skip to content

[codex] Route generated export through backend writer#801

Draft
ehennestad wants to merge 1 commit intozarr-support/2-add-lazy-array-generalizationfrom
zarr-support/3-backend-writer
Draft

[codex] Route generated export through backend writer#801
ehennestad wants to merge 1 commit intozarr-support/2-add-lazy-array-generalizationfrom
zarr-support/3-backend-writer

Conversation

@ehennestad
Copy link
Copy Markdown
Collaborator

Motivation

This change decouples generated export code from raw HDF5 file identifiers by routing export operations through a backend writer object.

The generated export methods now accept a writer and call writer methods instead of calling io.writeGroup, io.writeDataset, and io.writeAttribute directly. The handwritten export helpers on the same path were updated to normalize either a writer object or legacy file id input, and the HDF5 path now uses a thin HDF5Writer adapter so behavior stays functionally identical for existing HDF5 export.

This keeps the scope limited to the export path while removing another HDF5-hardcoded seam from the architecture.

How to test the behavior?

addpath(genpath('.'));
results = runtests({'tests.unit.nwbExportTest', 'tests.unit.dataPipeTest', 'tests.unit.linkTest', 'tests.unit.io.WriteTest'});
assertSuccess(results);

Checklist

  • Have you ensured the PR description clearly describes the problem and solutions?
  • Have you checked to ensure that there aren't other open or previously closed Pull Requests for the same change?
  • If this PR fixes an issue, is the first line of the PR description fix #XX where XX is the issue number?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant