Repository navigation
Open
Description
Follow-up to #6.
The response to Review 3 (Requirements > Mutability) says:
We agree with the reviewer's observation that mutation has costs (a rewritten central directory, orphaned entries, and a possibly spoiled "
zarr.jsonfirst" ordering, see the Drawbacks section), and we have not adopted mitigations such as a padded header, in order to keep the format compatible with general-purpose ZIP libraries.
Three issues:
- Wrong cross-reference. The Drawbacks section does not discuss a spoiled
zarr.json-first ordering. The relevant text is in the description ofjsonFirst("a writer that modifies an archive SHOULD ensure that the flags in the archive comment are consistent with the order of the central directory"). - Undersells the change made for Comment 4 (Responses on central directory ordering (#13, #15, #23) [stacked on #47] #48). The reviewer's scenario was that rewriting
zarr.jsonorphans the entry at the head of the file and appends the new version at the tail, "spoiling the file's 'zarr.json files come first' recommendation". Since Responses on central directory ordering (#13, #15, #23) [stacked on #47] #48, the recommendation concerns only the order of the central directory records, not of the entries, and the central directory is rewritten on every append. A rewrittenzarr.jsontherefore does not breakjsonFirstif the writer puts the central directory in order at the end of the writing session. This is the most direct answer to the reviewer's concern and should be stated. - Padding wording. "We have not adopted mitigations such as a padded header" reads as a rejection, while Drawbacks ("Updating an entry in place is generally not supported by ZIP libraries") describes padding by alignment/padding extra fields or by unused space between entries as permitted. Better: padding is permitted but not specified or required, to keep the format compatible with general-purpose ZIP libraries.
To do
- Fix the cross-reference (point to the
jsonFirstdescription and/or Access and mutability). - Add that the
zarr.json-first recommendation now concerns only the central directory, so in-place metadata updates do not spoil it if the central directory is reordered at the end of the writing session. - Reword the padding sentence as "permitted, not specified".
- Keep consistent with the outcome of MUST 8 (first local file header at offset 0): text and check_ozx.py disagree after an in-place edit #77 (MUST 8 after an in-place edit), which affects whether the root
zarr.jsoncan be rewritten without a repack.
Metadata
Metadata
Assignees
Labels
No labels
Activity