Bug 59776 - ZipPackagePropertiesMarshaller exception handling swallows root cause
Summary: ZipPackagePropertiesMarshaller exception handling swallows root cause
Status: REOPENED
Alias: None
Product: POI
Classification: Unclassified
Component: OPC (show other bugs)
Version: 3.15-dev
Hardware: PC All
: P2 enhancement (vote)
Target Milestone: ---
Assignee: POI Developers List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-07-01 09:10 UTC by Javen O'Neal
Modified: 2017-04-28 11:54 UTC (History)
1 user (show)



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Javen O'Neal 2016-07-01 09:10:10 UTC
Reported by Andrei Ivanov on user mailing list [1].
> But I still think it would be nice for the root exception to be
> preserved, for future cases, to avoid guessing.

[1] http://apache-poi.1045710.n5.nabble.com/Fail-to-save-stream-td5723711.html
Comment 1 Javen O'Neal 2016-07-01 09:15:29 UTC
Include cause in OpenXML4JException in r1750893.
Comment 2 Andrei Ivanov 2016-07-01 09:17:30 UTC
Wow, amazing response.
Thank you :-)
Comment 3 David North 2016-07-08 08:05:05 UTC
Javen, can we close this now?
Comment 4 Javen O'Neal 2016-07-08 08:56:47 UTC
I left it open because there's no unit test to verify this was fixed nor verification from Andrei that this fixed the problem [1].

There isn't currently a unit test class for ZipPackagePropertiesMarshaller and we don't have a file that can trigger this error.

If Andrei is waiting for the next release to test the change, then we might as well close it.

[1] http://apache-poi.1045710.n5.nabble.com/Fail-to-save-stream-tp5723711p5723731.html
Comment 5 Abhishek Kumar 2017-04-28 11:54:38 UTC
Hi Team,

I am still facing the issue again,after upgrading my poi version to 3.15.

Fail to save: an error occurs while saving the package : The part /docProps/app.xml fail to be saved in the stream with marshaller org.apache.poi.openxml4j.opc.internal.marshallers.DefaultMarshaller@3224e66a

Caused by: org.apache.poi.openxml4j.exceptions.OpenXML4JException: The part /docProps/app.xml fail to be saved in the stream with marshaller org.apache.poi.openxml4j.opc.internal.marshallers.DefaultMarshaller@3224e66a
	at org.apache.poi.openxml4j.opc.ZipPackage.saveImpl(ZipPackage.java:440)
	at org.apache.poi.openxml4j.opc.OPCPackage.save(OPCPackage.java:1375)
	at org.apache.poi.POIXMLDocument.write(POIXMLDocument.java:179)

Request your help.

Thanks-
Abhishek