Question

We have a fairly large Flex application and our QA were getting random, but reproducible, errors that the Flex developers couldn't reproduce. Some of these errors were being thrown from the flash player debug version such as:

ReferenceError: Specified ApplicationDomain does not contain the class ::LineSeriesLegendMarker
    at org.spicefactory.lib.reflect::ClassInfo$/getClassDefinitionByName()
    at org.spicefactory.lib.reflect::ClassInfo$/getClassInfo()
    at org.spicefactory.lib.reflect::ClassInfo$/forInstance()
    at org.spicefactory.parsley.core.view.impl::DefaultViewConfigurator/getDefinitionByType()
    at org.spicefactory.parsley.core.view.impl::DefaultViewConfigurator/getDefinition()
    at org.spicefactory.parsley.core.view.handler::ViewAutowireHandler/processAutowireEvent()
    at org.spicefactory.parsley.core.view.util::ContextAwareEventHandler/handleEvent()
    at org.spicefactory.parsley.core.view.handler::ViewAutowireHandler/handleAutowireEvent()
    at flash.events::EventDispatcher/dispatchEventFunction()
    at flash.events::EventDispatcher/dispatchEvent()
    at org.spicefactory.parsley.core.view.handler::ViewAutowireHandler/prefilterView()
    at flash.display::DisplayObjectContainer/addChildAt()
    at mx.core::UIComponent/http://www.adobe.com/2006/flex/mx/internal::$addChildAt()
    at mx.core::Container/addChildAt()
    at mx.core::Container/addChild()
    at mx.charts::Legend/addLegendItem()
    at mx.charts::Legend/populateFromArray()
    at mx.charts::Legend/commitProperties()
    at mx.core::UIComponent/validateProperties()
    at mx.managers::LayoutManager/validateProperties()
    at mx.managers::LayoutManager/doPhasedInstantiation()
    at mx.managers::LayoutManager/doPhasedInstantiationCallback()

Other errors include comboboxes not being populated correctly and what seems to be just general timing issues.

I'd like to emphasize that we've narrowed this down to our our main SWF with no other variables except the mxmlc parameter -debug=true vs -debug=false. Has anyone else encountered this or know why the builds would be resulting in different behavior?

Was it helpful?

Solution

You're going to have to show more code than that; mostly your parsley config.

The difference between debug=true and debug=false is that debug=true will not trace errors in the end product. Your developers should always run with debug=true and have the Flash Player Debug installed.

Also, I'm curious as to why Parsley needs to know about view components. Are you using the Configure tag? I recommend you do not use it and instead use FastInject with proper presenter models which is better for testability. Configure means that Parsley have to reflect all the properties within your view which is useless and time consuming. I guarantee if you use FastInject instead of Configure that your problem would disappear. That is unless you're trying to inject a view into a components, which you shouldn't do. If that's the case, you'll need to architect your application in a better way.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top