2

After a fresh install of Repast Symphony 2.5.0 (Win 64bit) and JDK 9.0.1 on a Windows 10 system, when importing a JZombies_Demo example, the model cannot be launched with the default configuration.

The error says:

    An internal error occurred during: "Launching JZombies_Demo Model".
    org.codehaus.groovy.eclipse.core.builder.GroovyClasspathContainer.<init>(Lorg/eclipse/core/resources/IProject;)V

When I edit the default run configuration, in the Dependencies tab I see only the JRE System Library and nothing else. In the same tab, the Restore Default Entries is enabled - when I press it all the dependencies from Repast Symphony are added, and the previous error disappears. However, in this case when trying to launch another error is observed:

     saf.core.runtime.Boot - null
     java.lang.NullPointerException
     at saf.core.runtime.Boot.init(Boot.java:79)
     at saf.core.runtime.Boot.main(Boot.java:246)
     at repast.simphony.runtime.RepastMain.main(RepastMain.java:43)

I also read about this problem on Repast Mailing List, and saw people talking about missing boot.properties file in the X\eclipse\plugins\repast.simphony.runtime_2.5.0 folder. However, the file is well in place there. So, I tried to link this to the previous error and saw that at (RepastMain.java:43) the pathInfo value was actually X\eclipse\plugins\repast.simphony.bin_and_src_2.5.0. Thus I tried to copy the boot.properties from the runtime directory to the bin_and_src - this removed the previous error, but brought a number of warnings related to UI initialization and an error:

     repast.simphony.ui.RSUIPlugin - Fatal error starting Repast
     java.lang.NoSuchMethodError: com.jgoodies.forms.layout.ColumnSpec.createGap(Lcom/jgoodies/forms/layout/ConstantSize;)Lcom/jgoodies/forms/layout/ColumnSpec;
at com.jgoodies.forms.layout.FormSpecs.<clinit>(FormSpecs.java:115)
at repast.simphony.ui.RunOptionsPanel.initComponents(RunOptionsPanel.java:114)
at repast.simphony.ui.RunOptionsPanel.<init>(RunOptionsPanel.java:39)
at repast.simphony.ui.RSGui.addRunOptionsView(RSGui.java:558)
at repast.simphony.ui.RSApplication.initGui(RSApplication.java:655)
at repast.simphony.ui.RSAppConfigurator.fillBars(RSAppConfigurator.java:52)
at saf.core.ui.GUICreatorDelegate.createDisplay(GUICreatorDelegate.java:160)
at saf.core.ui.GUICreator.createDisplay(GUICreator.java:12)
at repast.simphony.ui.RSUIPlugin$1.run(RSUIPlugin.java:102)
at java.desktop/java.awt.event.InvocationEvent.dispatch(Unknown Source)
at java.desktop/java.awt.EventQueue.dispatchEventImpl(Unknown Source)
at java.desktop/java.awt.EventQueue.access$500(Unknown Source)
at java.desktop/java.awt.EventQueue$3.run(Unknown Source)
at java.desktop/java.awt.EventQueue$3.run(Unknown Source)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at java.base/java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
at java.desktop/java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.desktop/java.awt.EventDispatchThread.run(Unknown Source)

After seeing all that, enough frustration, and tries to reinstall the Repast and JDK the situation remained unchanged. Also need to note, that the same behavior is observed for other examples, and newly created Repast projects.

Would be very glad to hear your opinions on what can cause such Repast behavior.

iammain
  • 43
  • 3

1 Answers1

5

It looks like this is an issue with Java 9 compatibility. Can you try a fresh install using the latest Java 8? In the meantime we'll follow up on what changes in Repast Simphony will be needed for Java 9 compatibility.

J. Ozik
  • 1,083
  • 5
  • 6
  • I tried 2 things: 1) Installed the JDK 8.0.151 and the exact same problems persist; 2) Installed Repast 2.5.0 and JDK 8.0151 on another Windows 7 machine - no problems with the launches. However, there was another thing I noticed, which is linked to the original problem. The Repast example launch configuration classpath in the user entries contains Repast Interactive Runtime Libraries (this works fine), whilst when I click on Restore Default Values the runtime libraries are replaced with defaut classpath which contains Repast Development Libraries instead (this does not work anymore). – iammain Dec 08 '17 at 08:52
  • For 1) have you by any chance updated the Groovy plugin from what's included with the Windows Repast Simphony 2.5 installation? For 2) just to be clear, if you don't click on Restore Default Values everything works fine? – J. Ozik Dec 08 '17 at 20:40
  • 1) Yes, I used the in-built Check for updates functionality for Groovy plugin. That indeed might be one of the reasons. Just tried running the example project again without any updates - I see some warnings first: `Illegal reflective access by com.thoughtworks.xstream.core.util.Fields ... to field java.util.TreeMap.comparator`. Then the model finally starts (good news), but with lots of `java.lang.NumberFormatException: For input string: ""` coming from `repast.simphony.ui.RSUIPlugin$1.run(RSUIPlugin.java:104)`. But this is a different problem... 2) Yes, in that case all is fine. Thanks! – iammain Dec 11 '17 at 10:00
  • 3
    If you have a reason to update the Groovy plugin then the only current way to make the Repast Simphony plugin work would be to uninstall it and then install it again from the Repast Simphony update site: https://repocafe.cels.anl.gov/repos/repast . Alternatively, you could also not update the Groovy plugin and 2.5.0 should work out of the box. – J. Ozik Dec 11 '17 at 20:35