-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Saving workbook with reverse sorted internal part path to keep same hash of identical files #1890
Conversation
Update zip sort order Original order ``` [Content_Types].xml _rels/.rels docProps/app.xml docProps/core.xml xl/_rels/workbook.xml.rels xl/sharedStrings.xml xl/styles.xml xl/theme/theme1.xml xl/workbook.xml xl/worksheets/sheet2.xml xl/worksheets/sheet3.xml xl/worksheets/sheet4.xml xl/worksheets/sheet5.xml xl/worksheets/sheet6.xml xl/worksheets/sheet7.xml xl/worksheets/sheet8.xml xl/worksheets/sheet9.xml ``` New order ``` xl/_rels/workbook.xml.rels xl/pivotCache/pivotCacheDefinition1.xml xl/pivotTables/_rels/pivotTable1.xml.rels xl/pivotTables/pivotTable1.xml xl/sharedStrings.xml xl/styles.xml xl/theme/theme1.xml xl/workbook.xml xl/worksheets/_rels/sheet8.xml.rels xl/worksheets/sheet1.xml xl/worksheets/sheet12.xml xl/worksheets/sheet2.xml xl/worksheets/sheet3.xml xl/worksheets/sheet4.xml xl/worksheets/sheet5.xml xl/worksheets/sheet6.xml xl/worksheets/sheet7.xml xl/worksheets/sheet8.xml [Content_Types].xml _rels/.rels docProps/app.xml docProps/core.xml ```
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could you follow the pull request template, explain why is this change required and what problem does it solve?
Saving workbook with reverse sorted internal part path to keep same hash of identical files
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #1890 +/- ##
=======================================
Coverage 99.21% 99.21%
=======================================
Files 32 32
Lines 24085 24085
=======================================
Hits 23895 23895
Misses 102 102
Partials 88 88
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your pull request. I have made some changes based on your code.
This closes qax-os#1889, refs qax-os#1732 and qax-os#1735 (qax-os#1890)
Update zip sort order
Original order
New order
PR Details
Description
This change sorts the inter zip streams so that the Excel file passes validation as a Microsoft Excel 2007+
Related Issue
Motivation and Context
How Has This Been Tested
This change was tested and verified that the resulting output includes the Microsoft Excel 2007+ metadata to show up properly using
file
tool, andmmmagic
.Run on Mac OS.
Upload of the file to a server now shows it is a proper xlsx file.
This change doesn't affect other areas of the code.
Types of changes
Checklist