On 04/17/2015 06:47 PM, Rolf Huehne wrote: > On 04/17/2015 01:44 PM, Rolf Huehne wrote: >> Hi all, >> >> I have some problems debugging a complex script in Jmol. >> >> First of all, the command 'set scriptReportingLevel' doesn't seem to >> work in Jmol 14.3.13_2015.04.08. It is always setting the value to zero. >> >> Q: What do the numbers (e.g.: $[2.295.299]) in the debugging output >> after the command 'set showScript on' mean? >> >> The first number looks like it could be the function call level. >> The third number could be the line number within the function after >> removing empty lines. >> >> Following the debugging information for a problematic function (~500 >> lines of code, see short extract below) the critical line seems to be a >> 'for' loop. Depending on the input data the loop sometimes cycles more >> often (twice instead of once) than indicated by the variable value >> ('fileCount=1' in any of the described cases) or the function is exited >> (without any error message or exception) after reaching the line the >> second time: >> > I found another problem inside the function that leads to an > extraordinary function exit. For this one I could narrow down the problem. > The following example function demonstrates it: if you try to loop over > an empty hash the function is exited too early. > It looks like this was actually also causing the other exit problem, although it wasn't occuring near a loop over a hash. But after I have introduced a size check before every loop over a hash the function seems to be running now as expected on the tested datasets.
Regards, Rolf -- Rolf Huehne Postdoc Leibniz Institute for Age Research - Fritz Lipmann Institute (FLI) Beutenbergstrasse 11 07745 Jena, Germany Phone: +49 3641 65 6205 Fax: +49 3641 65 6210 E-Mail: rhue...@fli-leibniz.de Website: http://www.fli-leibniz.de Scientific Director: Prof. Dr. K. Lenhard Rudolph Head of Administration: Dr. Daniele Barthel Chairman of Board of Trustees: Dennys Klein VAT No: DE 153 925 464 Register of Associations: No. 230296, Amtsgericht Jena Tax Number: 162/141/08228 ------------------------------------------------------------------------------ BPM Camp - Free Virtual Workshop May 6th at 10am PDT/1PM EDT Develop your own process in accordance with the BPMN 2 standard Learn Process modeling best practices with Bonita BPM through live exercises http://www.bonitasoft.com/be-part-of-it/events/bpm-camp-virtual- event?utm_ source=Sourceforge_BPM_Camp_5_6_15&utm_medium=email&utm_campaign=VA_SF _______________________________________________ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers