Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Document loading/parsing errors #28

Open
tuxmark5 opened this issue Aug 18, 2020 · 0 comments
Open

Document loading/parsing errors #28

tuxmark5 opened this issue Aug 18, 2020 · 0 comments

Comments

@tuxmark5
Copy link

I've been using docx crate in one of my projects for a while and over time I've run into a few documents that fail to load with this crate.

element_end.docx:
Xml(UnexpectedToken { token: "ElementEnd { end: Empty, span: StrSpan(\"/>\" 487..489) }" })

invalid_digit.docx:
Xml(FromStr(ParseIntError { kind: InvalidDigit }))

missing_content.docx:
Xml(MissingField { name: "Hyperlink", field: "content" })

missing_id.docx:
Xml(MissingField { name: "NumberingProperty", field: "id" })

missing_level.docx:
Xml(MissingField { name: "NumberingProperty", field: "level" })

unkown_value_right.docx
Xml(FromStr("Unkown Value. Found right, Expected "start", "end", "center","))
^ Also a typo in the error message (Unkown -> Unknown).

Most of the documents fail to load because of the missing id/level in NumberingProperty and unknown right value. The other errors are quite rare.

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

No branches or pull requests

1 participant