Ah great. I've noticed that the event hitting that method is not actually of type ChannelFaultEvent, but just plain Event.
I've occasionally noticed this behavior while working with Royale these last couple years -- where the expected event type is sometimes plain old Event instead of the actual type declared. -----Original Message----- From: Greg Dove <greg.d...@gmail.com> Sent: Thursday, April 7, 2022 12:00 PM To: Apache Royale Development <dev@royale.apache.org> Subject: [EXTERNAL] Re: Problem with Release 0.9.9 and 0.9.10-SNAPSHOT Brian, I have an idea what it might be. There was a change for event redispatching to align more with the way flash does it natively. It could be incomplete or unimplemented event cloning support. I will look into this over the weekend. On Fri, 8 Apr 2022, 5:51 am Brian Raymes, <brian.ray...@teotech.com> wrote: > Hello all, > > It appears that something slipped through right before the 0.9.9 > release that breaks MX RemoteObjects/Consumers. > > I've attempted rolling through and reverting various recent commits to > try to narrow down the problem, but have yet to be able to find one related. > > To provide context, I've been building on the 0.9.9-SHAPSHOT up to and > in the middle of the latest release. Sometime around when the release > came out, this method, from MessageAgent.as (MX), now fails: > > public function channelFaultHandler(event:ChannelFaultEvent):void > { > if (Log.isWarn()) > _log.warn("'{0}' {1} channel faulted with {2} {3}", id, > _agentType, event.faultCode, event.faultDetail); > > if (!event.channel.connected) <--<--<--<--<-- HERE <--<--<--<--<-- > { > setConnected(false); > // If we have remoteCredentials we need to send them on > reconnect. > if (_remoteCredentials != null) > { > _sendRemoteCredentials = true; > } > } > dispatchEvent(event); > } > > If reverting my project to run off the 0.9.8 release, everything runs > as expected. If I were to revert the compiler/framework to sometime > before the release, everything worked as expected as well. > > Exception has occurred: TypeError: Cannot read properties of undefined > (reading 'connected') > at mx.rpc.AsyncRequest.mx.messaging.MessageAgent.channelFaultHandler > ( > http://localhost/mx/messaging/MessageAgent.js:464:22) > at > mx.rpc.AsyncRequest.mx.messaging.AbstractProducer.channelFaultHandler > (http://localhost/mx/messaging/AbstractProducer.js:158:65) > at > mx.messaging.ChannelSet.org.apache.royale.events.EventDispatcher.fireL > isteners > (http://localhost/org/apache/royale/events/EventDispatcher.js:102:23) > at Function.goog.events.EventTarget.dispatchEventInternal_ ( > http://localhost/library/closure/goog/events/eventtarget.js:381:26) > at > mx.messaging.ChannelSet.org.apache.royale.events.EventDispatcher.dispa > tchEvent > (http://localhost/org/apache/royale/events/EventDispatcher.js7:77:37) > at mx.messaging.ChannelSet.channelFaultHandler ( > http://localhost/mx/messaging/ChannelSet.js:618:10) > at > mx.messaging.channels.AMFChannel.org.apache.royale.events.EventDispatc > her.fireListeners > (http://localhost/org/apache/royale/events/EventDispatcher.js:102:23) > at Function.goog.events.EventTarget.dispatchEventInternal_ ( > http://localhost/library/closure/goog/events/eventtarget.js:381:26) > at > mx.messaging.channels.AMFChannel.org.apache.royale.events.EventDispatc > her.dispatchEvent > (http://localhost/org/apache/royale/events/EventDispatcher.js77:37) > at > mx.messaging.channels.PollingChannel.PollCommandMessageResponder.statu > sHandler > (http://localhost/mx/messaging/channels/PollingChannel.js:824:18) > > > If there is anything I can provide to further assist, please let me know. > > Thank you. > > Brian > >