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

XML export error #150

Closed
bittremieux opened this issue Dec 5, 2019 · 4 comments
Closed

XML export error #150

bittremieux opened this issue Dec 5, 2019 · 4 comments
Labels

Comments

@bittremieux
Copy link

I get the following error when PIA tries to write its XML output:

[05-Dec-2019 14:00:56 - INFO] "Writing PIA XML file to /home/wout/Downloads/b10000_ZNF230.xml" (de.mpc.pia.intermediate.compiler.PIACompiler:918)
[05-Dec-2019 14:00:56 - INFO] "Stream open, writing PIA XML" (de.mpc.pia.intermediate.compiler.PIACompiler:942)
[05-Dec-2019 14:00:56 - ERROR] "JAXBException while writing XML file" (de.mpc.pia.intermediate.compiler.PIACompiler:989)
javax.xml.bind.JAXBException
- with linked exception:
[java.lang.ClassNotFoundException: com.sun.xml.internal.bind.v2.ContextFactory]
at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:241)
at javax.xml.bind.ContextFinder.find(ContextFinder.java:455)
at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:652)
at javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:599)
at de.mpc.pia.intermediate.compiler.PIACompiler.createMarshallerForPiaXML(PIACompiler.java:1007)
at de.mpc.pia.intermediate.compiler.PIACompiler.marshalToFormattedFragmentMarshaller(PIACompiler.java:1030)
at de.mpc.pia.intermediate.compiler.PIACompiler.writeOutJaxbFilesList(PIACompiler.java:1080)
at de.mpc.pia.intermediate.compiler.PIACompiler.writeOutXML(PIACompiler.java:961)
at de.mpc.pia.intermediate.compiler.PIACompiler.writeOutXML(PIACompiler.java:919)
at de.mpc.pia.intermediate.compiler.PIACompiler.writeOutXML(PIACompiler.java:932)
at de.mpc.pia.intermediate.compiler.PIACompiler.main(PIACompiler.java:1273)
Caused by: java.lang.ClassNotFoundException: com.sun.xml.internal.bind.v2.ContextFactory
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:602)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
at javax.xml.bind.ContextFinder.safeLoadClass(ContextFinder.java:573)
at javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:239)
... 10 more
[05-Dec-2019 14:00:56 - INFO] "Writing of PIA XML file finished." (de.mpc.pia.intermediate.compiler.PIACompiler:996)

Could this be due to an outdated version of JAXB that's not compatible with my Java version? For example, see jakartaee/jaxb-api#78 and https://stackoverflow.com/a/43574427.

I'm using Java version 13.0.1, while the pom file seems to indicate a PRIDE version 1.0.22 of JAXB is used. Is this even the standard JAXB version number? If so, it seems a pretty old one and an update to JAXB version 2.4 seems useful to support current Java versions.

@julianu
Copy link
Contributor

julianu commented Dec 6, 2019

Yes, this is a JAXB incompatibility with new Java versions (new being >= 9).
Did you download the latest version or tried directly the GitHub version? If the version, could you please try the GitHub version. I had this problem before and at least for some versions it is fixed, but not released yet.

@julianu julianu added the bug label Dec 6, 2019
@bittremieux
Copy link
Author

bittremieux commented Dec 9, 2019

This was with version 1.3.10, the latest release available on here.

Do you mean to build the jar from master instead?

@julianu
Copy link
Contributor

julianu commented Dec 10, 2019

I just figured out the JAXB dependency was only in my private branch up to now. A new release was just added which should contain a fix for this.
Please let me know, whether this solves the issue.

@bittremieux
Copy link
Author

Yes, the JAXB error is fixed for version 1.3.11. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants