@/Lorien/
Can you file a bug at JIRA with this testcase? To workaround this bug (actually these bugs, there are two), you can simply omit the data declaration, because "data" is already defined in LzNode, so the definition in TestNode doesn't bring any benefits.

@Henry
The definition of "data" triggers the "data"-setter, which attempts to create a datapath. But a datapath always tries to find a parent-datapath, this is done by calling seachParents on its immediateparent. Now, in debug-mode, you get the "searchParents got null immediateparent" error, whereas in non-debug mode, the (flash) application crashes (the while-loop in seachParents doesn't terminate). That's bug #1, bug #2 is in "LzDatapath#construct(..)", the "unexpected state for '%w', couldn't find parent-datapath!" debug warning, I think we can remove it (and add instead a `null`-check in "LzDatapath#setDataContext()").



It seems to happen when I create an instance of a class that contains an attribute named "data". The following code gives the error:

<canvas>
     <class name="TestNode" extends="node">

         <attribute name="data" value="null"/>

     </class>

     <handler name="oninit" args="IGNORE_THIS_ARG">
         new lz.TestNode();
     </handler>
</canvas>

Whereas if I pass canvas in as the parent in the constructor the error goes away like so:

<canvas>
     <class name="TestNode" extends="node">

         <attribute name="data" value="null"/>

     </class>

     <handler name="oninit" args="IGNORE_THIS_ARG">
         new lz.TestNode(canvas);
     </handler>
</canvas>

The problem is only there if the data attribute is present.

Lorien


On Tue, Dec 16, 2008 at 2:58 PM , Henry Minsky wrote:

>/ That may be a warning that isn't really needed, it might have been put
/>/ it to debug
/>/ while bringing up the LFC in swf9. I think maybe we can remove the />/ warning from
/>/ the LFC, but if you can, send me a small
/>/ test case to check what is happening, please do.
/>/////
/>/
/>/ On Tue, Dec 16, 2008 at 5:29 PM, Lorien Henry-Wilkins
/>/ <lhenrywilkins at laszlosystems.com 
<http://www.openlaszlo.org/mailman/listinfo/laszlo-dev>> wrote:
/>>/ Hi guys,
/>>/
/>>/ There are cases in our LZX that we create new instances without />>/ passing in a />>/ parent argument - for example "new lz.datarequest()". I believe this />>/ is />>/ causing an issue in 4.2 - we are seeing a bunch of debugger errors />>/ that say />>/ "searchParents got null immediateparent". Is this no longer />>/ supported? What
/>>/ do you recommend as an alternative?
/>>/
/>>/ Thanks,
/>>/ Lorien
/>>/
/>/
/>/ -- />/ Henry Minsky
/>/ Software Architect
/>/ hminsky at laszlosystems.com 
<http://www.openlaszlo.org/mailman/listinfo/laszlo-dev>
/

Reply via email to