test(xlsx): validate the comments, theme and app properties as well - #555
Merged
Conversation
Three more parts hucre writes, each against the schema that describes it:
`xl/commentsN.xml` is SpreadsheetML, `xl/theme/theme1.xml` is DrawingML
like the charts, and `docProps/app.xml` has its own shared schema. All
valid.
79 parts across eleven documents now.
What is still not checked, and why, is recorded next to the mapping
rather than left to be rediscovered:
[Content_Types].xml, *.rels, docProps/core.xml
their schemas are in ECMA-376 Part 2 (OPC), a separate download from
the Part 4 set this script asks for
xl/drawings/vmlDrawing*.vml
`vml-main.xsd` does not load in `javax.xml.validation` at all — it
throws before reading any document. VML is a legacy format with a
famously loose schema and this is not the place to fight it
pnpm test green — 10,571 tests, 232 files.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Three more parts hucre writes, each against the schema that describes it:
xl/commentsN.xmlsml.xsd(SpreadsheetML)xl/theme/theme1.xmldml-main.xsd— the theme is DrawingML, like the chartsdocProps/app.xmlshared-documentPropertiesExtended.xsdAll valid. 79 parts across eleven documents now.
What is still not checked, and why
Recorded next to the mapping rather than left to be rediscovered:
[Content_Types].xml,*.rels,docProps/core.xml— their schemas are in ECMA-376 Part 2 (OPC), a separate download from the Part 4 set this script asks for.xl/drawings/vmlDrawing*.vml—vml-main.xsddoes not load injavax.xml.validationat all; it throws before reading any document. VML is a legacy format with a famously loose schema, and this is not the place to fight it.One correction while checking this: I first reported the comments part as unreached. It was reached and valid — my
grepused process substitution inside a compound command and silently matched nothing. The script was right and the check on it was wrong.pnpm testgreen — 10,571 tests, 232 files.🤖 Generated with Claude Code