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

odf files that generated by odf-report v0.7.0 be recognized as "broken file" in Microsoft Word #104

Closed
y-yagi opened this issue Mar 23, 2020 · 3 comments

Comments

@y-yagi
Copy link
Contributor

y-yagi commented Mar 23, 2020

Before odf-report v0.7.0, odf-report generated file be recognized as correct file in Microsoft Word, but now be recognized as "broken file".
I checked difference of generated odt files that between v0.6.1 and v0.7.0. There was difference of META-INF/manifest.xml.

$ diff -r odf-report-0.6.1 odf-report-0.7.0
diff -r odf-report-0.6.1/META-INF/manifest.xml odf-report-0.7.0/META-INF/manifest.xml
1,2c1,2
< <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
< <manifest:manifest xmlns:manifest="urn:oasis:names:tc:opendocument:xmlns:manifest:1.0"><manifest:file-entry manifest:full-path="/" manifest:media-type="application/vnd.oasis.opendocument.text"/><manifest:file-entry manifest:full-path="content.xml" manifest:media-type="text/xml"/><manifest:file-entry manifest:full-path="styles.xml" manifest:media-type="text/xml"/><manifest:file-entry manifest:full-path="settings.xml" manifest:media-type="text/xml"/><manifest:file-entry manifest:full-path="meta.xml" manifest:media-type="text/xml"/></manifest:manifest>
\ No newline at end of file
---
> <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
> <manifest:manifest xmlns:manifest="urn:oasis:names:tc:opendocument:xmlns:manifest:1.0"><manifest:file-entry manifest:full-path="/" manifest:media-type="application/vnd.oasis.opendocument.text"/><manifest:file-entry manifest:full-path="content.xml" manifest:media-type="text/xml"/><manifest:file-entry manifest:full-path="styles.xml" manifest:media-type="text/xml"/><manifest:file-entry manifest:full-path="settings.xml" manifest:media-type="text/xml"/><manifest:file-entry manifest:full-path="meta.xml" manifest:media-type="text/xml"/></manifest:manifest> 

It seems that cause of that newline.

This newlined added by 96a2173 . Is this an intentional? Thanks!

@sandrods
Copy link
Owner

sandrods commented Mar 23, 2020

Nope. No intentional. This must by a side-effect of having to edit the menifest to include the images added by tables and sections rendering.

I'll take a look. Are you able to confirm that the newline is actually the cause. Could you edit (unzip) the odt, change the xml and see if it solves the problem?

@y-yagi
Copy link
Contributor Author

y-yagi commented Mar 24, 2020

I checked with the edited(removed the newline at end of file) odt file with Microsoft Word and confirmed that recognized as a correct file.
(I guess Microsoft Word expects CR for a newline.)

@sandrods
Copy link
Owner

Good! That should be easy to fix, I'll take a look ASAP

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

2 participants