zward / Amua

An open source modeling framework
GNU General Public License v3.0
33 stars 11 forks source link

cannot run model anymore #59

Closed MMP24 closed 1 year ago

MMP24 commented 1 year ago

Hi Zach,

Since this afternoon, I'm suddenly no longer able to run my model, check my tree, run scenarios, export data. Essentially I cannot do anything anymore.

The java error says: Tue Jan 10 00:53:39 CET 2023 java.lang.NullPointerException Message: null Trace: tree.DecisionTree.parseTree(DecisionTree.java:205) base.AmuaModel.parseModel(AmuaModel.java:810) gui.frmScenarios$15$1.run(frmScenarios.java:629)

Any solution to this?

zward commented 1 year ago

Looks like the model is trying to parse variable updates for a node, but that the updates are empty. Is there an empty variable updates textbox attached to one of the nodes?

MMP24 commented 1 year ago

I was updating a parameter before the model stopped working, switched from a normal distribution to a triangular distribution. Nothing special that I haven't done before. But no empty updates to my knowledge...

zward commented 1 year ago

If you send me a copy of your model (zward@hsph.harvard.edu) I can debug and see what's going on

zward commented 1 year ago

There was an empty variable updates textbox causing the error, but it was attached to a node in a collapsed branch, making it difficult to see. One workaround is to go into the .amua file and find "true" and change it to "false" where needed. I will also change the code for the next release to check for this when parsing the tree.