Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Don't break when docProps/core.xml contains a <cp:version> tag#436

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
guyonroche merged 1 commit intoexceljs:masterfrompeakon:fix/cpVersionTag
Nov 21, 2017

Conversation

papandreou
Copy link
Contributor

@papandreoupapandreou commentedNov 15, 2017
edited
Loading

I've run into an .xlsx that contains a<cp:version> tag indocProps/core.xml:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?><cp:corePropertiesxmlns:cp="http://schemas.openxmlformats.org/package/2006/metadata/core-properties"xmlns:dc="http://purl.org/dc/elements/1.1/"xmlns:dcterms="http://purl.org/dc/terms/"xmlns:dcmitype="http://purl.org/dc/dcmitype/"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><dc:title>...</dc:title><dc:creator>...</dc:creator><cp:lastModifiedBy>...</cp:lastModifiedBy><cp:lastPrinted>2017-05-15T16:17:00Z</cp:lastPrinted><dcterms:createdxsi:type="dcterms:W3CDTF">2015-07-15T16:27:34Z</dcterms:created><dcterms:modifiedxsi:type="dcterms:W3CDTF">2017-09-06T15:39:12Z</dcterms:modified><cp:version></cp:version></cp:coreProperties>

This made exceljs break with:

Unexpected xml node in parseOpen: {"name":"cp:version","attributes":{},"isSelfClosing":false}

This PR fixes that by providing a parser for that property.

I would have liked to include a regression test with an actual LibreOffice document, but the most recent version of LibreOffice doesn't seem to include the tag, and I'm unable to share the spreadsheet that actually caused the problem as it includes sensitive data.

@guyonroche
Copy link
Collaborator

I've added that core.xml file as a unit test, that should do...

papandreou reacted with hooray emoji

@guyonrocheguyonroche merged commit3f4f819 intoexceljs:masterNov 21, 2017
@papandreou
Copy link
ContributorAuthor

Ah, good idea. Thanks!

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

2 participants
@papandreou@guyonroche

[8]ページ先頭

©2009-2025 Movatter.jp