Summary
Three low-severity residues in PackageInspector.imageConsistencyReport (3.7.0, PR #141), all recorded by the R5 logic lens, none reachable from a real package:
- L8 — a part or rels that exists but cannot be read (
Data(contentsOf:) failing after identity said it is a regular file) escapes as the raw Cocoa error instead of WordError.invalidDocx. Every other "no verdict" path throws invalidDocx.
- L9 — a part whose name is exactly the suffix (
word/.xml) is skipped by stem(of:ifSuffixed:)'s name.count > suffix.count guard, together with its rels.
- L6 — in pass 1, if
declare(part:) consumed a rels but scanPart were to fail before referencedByPart[part] is set, the declarations would become orphans; currently unreachable because scanPart records unparsable content parts.
Proposal
Wrap the two Data(contentsOf:) reads in the same invalidDocx envelope; decide whether .xml alone is a part name (probably: refuse it as a package the reader would not produce); add a comment or restructure pass 1 so the invariant is visible.
Source: surfaced during /idd-verify R5 of cluster PR #141 (#137 / #138 / #139), logic lens L6 / L8 / L9. Refs #137.
Summary
Three low-severity residues in
PackageInspector.imageConsistencyReport(3.7.0, PR #141), all recorded by the R5 logic lens, none reachable from a real package:Data(contentsOf:)failing afteridentitysaid it is a regular file) escapes as the raw Cocoa error instead ofWordError.invalidDocx. Every other "no verdict" path throwsinvalidDocx.word/.xml) is skipped bystem(of:ifSuffixed:)'sname.count > suffix.countguard, together with its rels.declare(part:)consumed a rels butscanPartwere to fail beforereferencedByPart[part]is set, the declarations would become orphans; currently unreachable becausescanPartrecords unparsable content parts.Proposal
Wrap the two
Data(contentsOf:)reads in the sameinvalidDocxenvelope; decide whether.xmlalone is a part name (probably: refuse it as a package the reader would not produce); add a comment or restructure pass 1 so the invariant is visible.Source: surfaced during
/idd-verifyR5 of cluster PR #141 (#137 / #138 / #139), logic lens L6 / L8 / L9. Refs #137.