[kepler-dev] stack overflow problem in some kepler

Edward A. Lee eal at eecs.berkeley.edu
Sun Jul 24 06:33:54 PDT 2005


I get the stack overflow error with Ptolemy II, so it isn't a Kepler
problem...

I've checked in a (partial) fix to diva.  Turns out diva's class
diva.canvas.toolbox.ImageFigure had a bug where if Java fails to load
a JPG file with an error, it would get a stack overflow.

My fix is to replace the image with a generic error image.

Christopher: Can you update the diva jar?

The reason that this is only a partial fix is that I have
no idea why Java would fail to load your JPG file.  Other programs
can load it without error...

Edward

At 04:51 PM 7/22/2005 -0700, Efrat Frank wrote:
>Hi Edward,
>
>I created a very simple example that uses a jpeg as a customized icon that 
>causes a stackOverflow. Attached are the workflow and the image file.
>
>Thanks a lot,
>Efrat
>
>Edward A. Lee wrote:
>
>>
>>If you send me the MoML file with the customized icons and the jpegs
>>for the icons, I can try to verify whether it is a Ptolemy II problem ...
>>
>>Edward
>>
>>At 02:47 PM 7/21/2005 -0700, Efrat Frank wrote:
>>
>>>Hi Dan,
>>>
>>>Thanks a lot for looking into this and detecting the problem! It does
>>>work fine without the customized icons.
>>>
>>>- Efrat
>>>
>>>Dan Higgins wrote:
>>>
>>> > Hi Efrat,
>>> >
>>> >    The stack overflow error that we get with the current head of CVS
>>> > on your gravityToShp workflow has been obsessing me the last few days
>>> > - why does it work with your saved version of Kepler and not with the
>>> > head of CVS?
>>> >
>>> >    It turns out that the problem occurs when you try to open the
>>> > workflow - i.e. when the workflow moml is being read. I finally traced
>>> > the problem not to any actor code but to the nice icons you added for
>>> > the XSLT actor and the Browser Display actor! (Those icons do not
>>> > appear if those actors are simply dragged to the screen, so I assume
>>> > you used the 'Edit Custom Icon' command.) If you go into the moml and
>>> > remove the properties that attach the custom icons, then the workflow
>>> > will open with the newest CVS version of Kepler!!!  [The
>>> > registrationModel workflow had a similar problem that is fixed by
>>> > removing the custom icons.]
>>> >
>>> >    Now, I don't know why the custom icons cause this problem (perhaps
>>> > some changes in the moml parsing?), but at least we know better where
>>> > to look!
>>> >
>>> > Dan
>>> >
>>>_______________________________________________
>>>Kepler-dev mailing list
>>>Kepler-dev at ecoinformatics.org
>>>http://mercury.nceas.ucsb.edu/ecoinformatics/mailman/listinfo/kepler-dev
>>
>>
>>------------
>>Edward A. Lee
>>Professor, Chair of the EE Division, Associate Chair of EECS
>>231 Cory Hall, UC Berkeley, Berkeley, CA 94720
>>phone: 510-642-0253 or 510-642-0455, fax: 510-642-2845
>>eal at eecs.Berkeley.EDU, http://ptolemy.eecs.berkeley.edu/~eal
>
>
>
><?xml version="1.0" standalone="no"?>
><!DOCTYPE entity PUBLIC "-//UC Berkeley//DTD MoML 1//EN"
>     "http://ptolemy.eecs.berkeley.edu/xml/dtd/MoML_1.dtd">
><entity name="testIcon" class="ptolemy.actor.TypedCompositeActor">
>     <property name="_createdBy" 
> class="ptolemy.kernel.attributes.VersionAttribute" value="5.1-devel">
>     </property>
>     <property name="SDF Director" 
> class="ptolemy.domains.sdf.kernel.SDFDirector">
>         <property name="entityId" class="org.kepler.moml.NamedObjId" 
> value="urn:lsid:ecoinformatics.org:kepler.300.1">
>         </property>
>         <property name="_location" class="ptolemy.kernel.util.Location" 
> value="[180.0, 135.0]">
>         </property>
>     </property>
>     <property name="_windowProperties" 
> class="ptolemy.actor.gui.WindowPropertiesAttribute" value="{bounds={279, 
> 125, 841, 800}, maximized=false}">
>     </property>
>     <property name="_vergilSize" class="ptolemy.actor.gui.SizeAttribute" 
> value="[600, 655]">
>     </property>
>     <property name="_vergilZoomFactor" 
> class="ptolemy.data.expr.ExpertParameter" value="1.0">
>     </property>
>     <property name="_vergilCenter" 
> class="ptolemy.data.expr.ExpertParameter" value="{300.0, 327.5}">
>     </property>
>     <entity name="Constant" class="ptolemy.actor.lib.Const">
>         <property name="entityId" class="org.kepler.moml.NamedObjId" 
> value="urn:lsid:localhost:actor:101:1">
>         </property>
>         <property name="semanticType" class="org.kepler.sms.SemanticType" 
> value="urn:lsid:lsid.ecoinformatics.org:onto:1:1#ConstantActor">
>         </property>
>         <property name="_icon" class="ptolemy.vergil.icon.BoxedValueIcon">
>             <property name="attributeName" 
> class="ptolemy.kernel.util.StringAttribute" value="value">
>             </property>
>             <property name="displayWidth" 
> class="ptolemy.data.expr.Parameter" value="40">
>             </property>
>         </property>
>         <property name="_location" class="ptolemy.kernel.util.Location" 
> value="[185.0, 250.0]">
>         </property>
>     </entity>
>     <entity name="Display" class="ptolemy.actor.lib.gui.Display">
>         <property name="_windowProperties" 
> class="ptolemy.actor.gui.WindowPropertiesAttribute">
>         </property>
>         <property name="entityId" class="org.kepler.moml.NamedObjId" 
> value="urn:lsid:localhost:actor:102:1">
>         </property>
>         <property name="_location" class="ptolemy.kernel.util.Location" 
> value="{320, 250}">
>         </property>
>         <property name="_icon" class="ptolemy.vergil.icon.EditorIcon">
>             <property name="image" 
> class="ptolemy.vergil.kernel.attributes.ImageAttribute">
>                 <property name="source" 
> class="ptolemy.data.expr.FileParameter" value="../../lib/images/xslt.jpg">
>                 </property>
>                 <property name="_location" 
> class="ptolemy.kernel.util.Location" value="[-20.0, -25.0]">
>                 </property>
>             </property>
>         </property>
>     </entity>
>     <relation name="relation" class="ptolemy.actor.TypedIORelation">
>         <property name="width" class="ptolemy.data.expr.Parameter" value="1">
>         </property>
>     </relation>
>     <link port="Constant.output" relation="relation"/>
>     <link port="Display.input" relation="relation"/>
></entity>

------------
Edward A. Lee
Professor, Chair of the EE Division, Associate Chair of EECS
231 Cory Hall, UC Berkeley, Berkeley, CA 94720
phone: 510-642-0253 or 510-642-0455, fax: 510-642-2845
eal at eecs.Berkeley.EDU, http://ptolemy.eecs.berkeley.edu/~eal  



More information about the Kepler-dev mailing list