NeuroML / org.neuroml.model

NeuroML v2 Java API
https://www.neuroml.org/neuromlv2
GNU Lesser General Public License v3.0
5 stars 3 forks source link

NPE when instantiating the NeuroML converter #18

Closed tarelli closed 8 years ago

tarelli commented 8 years ago

Some exceptions I am finding in the log. Doesn't happen all the time.

tarelli commented 8 years ago
org.neuroml.model.util.NeuroMLException: Problem loading NeuroML document 
[2016-02-12 16:02:51.826] ERROR ExperimentRunChecker         System.err                                                         at org.neuroml.model.util.NeuroMLConverter.loadNeuroML(NeuroMLConverter.java:131) 
[2016-02-12 16:02:51.826] ERROR ExperimentRunChecker         System.err                                                         at org.geppetto.model.neuroml.utils.OptimizedLEMSReader.readAllFormats(OptimizedLEMSReader.java:79) 
[2016-02-12 16:02:51.826] ERROR ExperimentRunChecker         System.err                                                         at org.geppetto.model.neuroml.services.LEMSModelInterpreterService.importType(LEMSModelInterpreterService.java:97) 
[2016-02-12 16:02:51.827] ERROR ExperimentRunChecker         System.err                                                         at org.geppetto.simulation.visitor.ImportTypesVisitor.caseImportType(ImportTypesVisitor.java:91) 
[2016-02-12 16:02:51.827] ERROR ExperimentRunChecker         System.err                                                         at org.geppetto.model.types.util.TypesSwitch.doSwitch(TypesSwitch.java:94) 
[2016-02-12 16:02:51.827] ERROR ExperimentRunChecker         System.err                                                         at org.eclipse.emf.ecore.util.Switch.doSwitch(Switch.java:53) 
[2016-02-12 16:02:51.827] ERROR ExperimentRunChecker         System.err                                                         at org.eclipse.emf.ecore.util.Switch.doSwitch(Switch.java:69) 
[2016-02-12 16:02:51.827] ERROR ExperimentRunChecker         System.err                                                         at org.geppetto.model.util.GeppettoModelTraversal.apply(GeppettoModelTraversal.java:52) 
[2016-02-12 16:02:51.827] ERROR ExperimentRunChecker         System.err                                                         at org.geppetto.simulation.manager.RuntimeProject.<init>(RuntimeProject.java:127) 
[2016-02-12 16:02:51.827] ERROR ExperimentRunChecker         System.err                                                         at org.geppetto.simulation.manager.GeppettoManager.loadProject(GeppettoManager.java:138) 
[2016-02-12 16:02:51.827] ERROR ExperimentRunChecker         System.err                                                         at org.geppetto.simulation.manager.ExperimentRunManager.runExperiment(ExperimentRunManager.java:143) 
[2016-02-12 16:02:51.827] ERROR ExperimentRunChecker         System.err                                                         at org.geppetto.simulation.manager.ExperimentRunChecker.run(ExperimentRunManager.java:304) 
[2016-02-12 16:02:51.827] ERROR ExperimentRunChecker         System.err                                                         at java.util.TimerThread.mainLoop(Timer.java:555) 
[2016-02-12 16:02:51.827] ERROR ExperimentRunChecker         System.err                                                         at java.util.TimerThread.run(Timer.java:505) 
[2016-02-12 16:02:51.828] ERROR ExperimentRunChecker         System.err                                                        Caused by: javax.xml.bind.UnmarshalException 
[2016-02-12 16:02:51.828] ERROR ExperimentRunChecker         System.err                                                         - with linked exception: 
[2016-02-12 16:02:51.828] ERROR ExperimentRunChecker         System.err                                                        [org.xml.sax.SAXException: FWK005 parse may not be called while parsing.] 
[2016-02-12 16:02:51.828] ERROR ExperimentRunChecker         System.err                                                         at javax.xml.bind.helpers.AbstractUnmarshallerImpl.createUnmarshalException(AbstractUnmarshallerImpl.java:335) 
[2016-02-12 16:02:51.828] ERROR ExperimentRunChecker         System.err                                                         at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.createUnmarshalException(UnmarshallerImpl.java:512) 
[2016-02-12 16:02:51.828] ERROR ExperimentRunChecker         System.err                                                         at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(UnmarshallerImpl.java:209) 
[2016-02-12 16:02:51.828] ERROR ExperimentRunChecker         System.err                                                         at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:175) 
[2016-02-12 16:02:51.828] ERROR ExperimentRunChecker         System.err                                                         at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:157) 
[2016-02-12 16:02:51.828] ERROR ExperimentRunChecker         System.err                                                         at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:214) 
[2016-02-12 16:02:51.828] ERROR ExperimentRunChecker         System.err                                                         at org.neuroml.model.util.NeuroMLConverter.loadNeuroML(NeuroMLConverter.java:128) 
[2016-02-12 16:02:51.828] ERROR ExperimentRunChecker         System.err                                                         ... 13 more 
[2016-02-12 16:02:51.828] ERROR ExperimentRunChecker         System.err                                                        Caused by: org.xml.sax.SAXException: FWK005 parse may not be called while parsing. 
[2016-02-12 16:02:51.829] ERROR ExperimentRunChecker         System.err                                                         at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1253) 
[2016-02-12 16:02:51.829] ERROR ExperimentRunChecker         System.err                                                         at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:649) 
[2016-02-12 16:02:51.829] ERROR ExperimentRunChecker         System.err                                                         at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(UnmarshallerImpl.java:203) 
[2016-02-12 16:02:51.829] ERROR ExperimentRunChecker         System.err                                                         ... 17 more 
tarelli commented 8 years ago
screen shot 2016-02-12 at 16 13 30 screen shot 2016-02-12 at 16 01 17
pgleeson commented 8 years ago

Can you send the NML it's trying to load?

tarelli commented 8 years ago

screen shot 2016-02-13 at 11 59 29

tarelli commented 8 years ago

@pgleeson I will as soon as I can reproduce it again, many times though the exceptions happens just when instantiating the NeuroMLConverter, no arguments passed, see above.

tarelli commented 8 years ago

@pgleeson @adrianq https://gist.github.com/tarelli/44d60119864ad5b7d216 there you go, however I noticed this happens after the previous one so maybe there's something already wrong beforehand that has to do with the schema.

pgleeson commented 8 years ago

@tarelli not sure if it's a problem with the gist or the file, but it's truncated at the end, no closing elements.

Is it something to do with the file not getting fully downloaded before being parsed?

pgleeson commented 8 years ago

Seems like this is no longer a problem for you @tarelli? Reopen if you see it again.