Nuclear Whiskers
Nuclear Whiskers

Reputation: 71

failed to create an XPathFactory

I'm trying to run LightSide (http://lightsidelabs.com/what/research/), a machine learning tool kit. However, when I run the included batch file, it crashes on the splash screen, and the log contains the following error.

Exception in thread "main" java.lang.ExceptionInInitializerError
    at edu.cmu.side.plugin.control.PluginManager.createPluginOfFolder(PluginManager.java:105)
    at edu.cmu.side.plugin.control.PluginManager.createPluginTypeMap(PluginManager.java:134)
    at edu.cmu.side.plugin.control.PluginManager.<init>(PluginManager.java:164)
    at edu.cmu.side.plugin.control.PluginManager.getSharedPluginManager(PluginManager.java:178)
    at edu.cmu.side.plugin.control.PluginManager.getSIDEPluginArrayByType(PluginManager.java:80)
    at edu.cmu.side.control.ExtractFeaturesControl.<clinit>(ExtractFeaturesControl.java:56)
    at edu.cmu.side.view.extract.ExtractFeaturesPane.<clinit>(ExtractFeaturesPane.java:24)
    at edu.cmu.side.view.WorkbenchPanel.<init>(WorkbenchPanel.java:21)
    at edu.cmu.side.Workbench.<init>(Workbench.java:65)
    at edu.cmu.side.Workbench.main(Workbench.java:96)
Caused by: java.lang.RuntimeException: XPathFactory#newInstance() failed to create an XPathFactory for the default object model: http://java.sun.com/jaxp/xpath/dom with the XPathFactoryConfigurationException: javax.xml.xpath.XPathFactoryConfigurationException: java.util.ServiceConfigurationError: javax.xml.xpath.XPathFactory: Provider oracle.xml.xpath.JAXPXPathFactory not found
    at javax.xml.xpath.XPathFactory.newInstance(Unknown Source)
    at com.mysterion.xml.XMLBoss.<clinit>(XMLBoss.java:93)
    ... 10 more

The source line causing this error (PluginManager.java:105) is the following line, which I recognize from other questions.

config = XMLBoss.XMLFromFile(configFile);

It seems that most problems originate from the programmer side, not the user side, so their solutions aren't relevant to my case. It's probably something to do with my Java installation, or that I'm missing a plugin or something, but the installation manual for this tool kit doesn't mention any installation outside of the usual Java installation.

I've been searching for hours, but I cannot figure out the problem. Does anyone have an idea?

Upvotes: 2

Views: 3089

Answers (1)

dadamson
dadamson

Reputation: 441

I'm one of the LightSide developers.

LightSide's dependency on XMLBoss is minimal (and ancient!) - it only uses a single convenience method which doesn't need the XMLBoss' statically-initialized XPath instance.

In the latest snapshot of LightSide, I've factored out XMLBoss from our plugin loader, creating an XMLDocument directly from an oracle.xml.parser.v2.DOMParser instead -- let me know if this fixes the issue.

http://ankara.lti.cs.cmu.edu/side/download.html#beta (the purple "dev snapshot" link)

Upvotes: 3

Related Questions