User e469f67125
01-10-2008 23:03:42
environment: JChem version 5_1_0, Java 1.6.0_03 (Sun JDK), Linux x86 32bit
Simply calling the default constructor:
results in a runtime exception and message "Failed to create default XML configuration." (traceback below).
However, the same code, same JChem version, with Java 1.6.0_07 works fine.
I have already found a workaround, by using the alternate constructor CFParameters(String xml), which works on the platform in question. So the main purpose of this post is to inform others and inform full resolution.
Simply calling the default constructor:
Code: |
CFParameters cfparams = new CFParameters(); |
results in a runtime exception and message "Failed to create default XML configuration." (traceback below).
However, the same code, same JChem version, with Java 1.6.0_07 works fine.
- $ java sim2d test.smi 'NCCc1ccccc1'
java.lang.NullPointerException
at org.jaxen.util.DescendantAxisIterator.hasNext(DescendantAxisIterator.java:94)
at org.jaxen.expr.DefaultStep.evaluate(DefaultStep.java:166)
at org.jaxen.expr.DefaultLocationPath.evaluate(DefaultLocationPath.java:154)
at org.jaxen.expr.DefaultAbsoluteLocationPath.evaluate(DefaultAbsoluteLocationPath.java:121)
at org.jaxen.expr.DefaultXPathExpr.asList(DefaultXPathExpr.java:112)
at org.jaxen.BaseXPath.selectNodesForContext(BaseXPath.java:688)
at org.jaxen.BaseXPath.selectNodes(BaseXPath.java:227)
at org.jaxen.BaseXPath.selectSingleNode(BaseXPath.java:248)
at org.dom4j.xpath.DefaultXPath.selectSingleNode(DefaultXPath.java:156)
at org.dom4j.tree.AbstractNode.selectSingleNode(AbstractNode.java:188)
at chemaxon.descriptors.CFParameters.processDocument(CFParameters.java:273)
at chemaxon.descriptors.MDParameters.initParameters(MDParameters.java:201)
at chemaxon.descriptors.CFParameters.initParameters(CFParameters.java:177)
at chemaxon.descriptors.CFParameters.setLength(CFParameters.java:127)
at chemaxon.descriptors.CFParameters.<init>(CFParameters.java:62)
at sim2d.main(sim2d.java:28)
Exception in thread "main" java.lang.RuntimeException: Failed to create default XML configuration.
at chemaxon.descriptors.MDParameters.initParameters(MDParameters.java:210)
at chemaxon.descriptors.CFParameters.initParameters(CFParameters.java:177)
at chemaxon.descriptors.CFParameters.setLength(CFParameters.java:127)
at chemaxon.descriptors.CFParameters.<init>(CFParameters.java:62)
at sim2d.main(sim2d.java:28)
I have already found a workaround, by using the alternate constructor CFParameters(String xml), which works on the platform in question. So the main purpose of this post is to inform others and inform full resolution.