powered by Jive Software

Exception in packet listener when joining a groupchat room

User did successfully joined the room, but I don’t know why I keep getting this error…

This is from the latest build : 4.2.0-beta3-SNAPSHOT

E/AbstractXMPPConnection: Exception in packet listener

                                                                        java.lang.ClassCastException: org.jivesoftware.smack.packet.Presence cannot be cast to org.jivesoftware.smack.packet.Message

                                                                            at org.jivesoftware.smackx.muc.MultiUserChat$4.processPacket(MultiUserChat.java:25 4)

                                                                            at org.jivesoftware.smack.AbstractXMPPConnection$5.run(AbstractXMPPConnection.java :1165)

                                                                            at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112)

                                                                            at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587)

                                                                            at java.lang.Thread.run(Thread.java:818)

Will be fixed in future versions of this snapshot release. But even with this exception being thrown, everything should work as expected. Thanks for reporting.

Yes, it is still working alright. Thank you. also one more [minor question]

when I tried to update the subject of a room, I get a timeout:

11-13 10:25:49.839 24243-24352/com.cyberprologue.cp D/SMACK: SENT (0): Changing subject topic-tst

11-13 10:25:50.040 24243-24353/com.cyberprologue.cp D/SMACK: RECV (0):

11-13 10:25:54.998 24243-24323/com.cyberprologue.cp W/System.err: org.jivesoftware.smack.SmackException$NoResponseException: No response received within reply timeout. Timeout was 5000ms (~5s). Waited for response using: AndFilter: (AndFilter: (FromMatchesFilter (ignoreResourcepart): mytest@group.myserver.com, MessageTypeFilter: type=groupchat), org.jivesoftware.smackx.muc.MultiUserChat$6@eea73a7).

11-13 10:25:55.012 24243-24323/com.cyberprologue.cp W/System.err: at org.jivesoftware.smack.PacketCollector.nextResultOrThrow(PacketCollector.java:2 53)

11-13 10:25:55.012 24243-24323/com.cyberprologue.cp W/System.err: at org.jivesoftware.smack.PacketCollector.nextResultOrThrow(PacketCollector.java:2 08)

11-13 10:25:55.012 24243-24323/com.cyberprologue.cp W/System.err: at org.jivesoftware.smackx.muc.MultiUserChat.changeSubject(MultiUserChat.java:1978 )

11-13 10:25:55.012 24243-24323/com.cyberprologue.cp W/System.err: at com.cyberprologue.cp.MyXMPP.MUC_init(MyXMPP.java:182)

11-13 10:25:55.012 24243-24323/com.cyberprologue.cp W/System.err: at com.cyberprologue.cp.MyXMPP$17.authenticated(MyXMPP.java:869)

11-13 10:25:55.012 24243-24323/com.cyberprologue.cp W/System.err: at org.jivesoftware.smack.AbstractXMPPConnection.callConnectionAuthenticatedListen er(AbstractXMPPConnection.java:1199)

11-13 10:25:55.012 24243-24323/com.cyberprologue.cp W/System.err: at org.jivesoftware.smack.AbstractXMPPConnection.afterSuccessfulLogin(AbstractXMPP Connection.java:563)

11-13 10:25:55.012 24243-24323/com.cyberprologue.cp W/System.err: at org.jivesoftware.smack.tcp.XMPPTCPConnection.afterSuccessfulLogin(XMPPTCPConnec tion.java:376)

11-13 10:25:55.012 24243-24323/com.cyberprologue.cp W/System.err: at org.jivesoftware.smack.tcp.XMPPTCPConnection.loginInternal(XMPPTCPConnection.ja va:440)

11-13 10:25:55.012 24243-24323/com.cyberprologue.cp W/System.err: at org.jivesoftware.smack.AbstractXMPPConnection.login(AbstractXMPPConnection.java :482)

11-13 10:25:55.012 24243-24323/com.cyberprologue.cp W/System.err: at org.jivesoftware.smack.AbstractXMPPConnection.login(AbstractXMPPConnection.java :456)

11-13 10:25:55.012 24243-24323/com.cyberprologue.cp W/System.err: at com.cyberprologue.cp.MyXMPP.login(MyXMPP.java:843)

11-13 10:25:55.014 24243-24323/com.cyberprologue.cp W/System.err: at com.cyberprologue.cp.MyXMPP$15.doInBackground(MyXMPP.java:745)

11-13 10:25:55.014 24243-24323/com.cyberprologue.cp W/System.err: at com.cyberprologue.cp.MyXMPP$15.doInBackground(MyXMPP.java:734)

11-13 10:25:55.014 24243-24323/com.cyberprologue.cp W/System.err: at android.os.AsyncTask$2.call(AsyncTask.java:295)

11-13 10:25:55.014 24243-24323/com.cyberprologue.cp W/System.err: at java.util.concurrent.FutureTask.run(FutureTask.java:237)

11-13 10:25:55.014 24243-24323/com.cyberprologue.cp W/System.err: at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:234)

11-13 10:25:55.014 24243-24323/com.cyberprologue.cp W/System.err: at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1113)

11-13 10:25:55.014 24243-24323/com.cyberprologue.cp W/System.err: at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:588)

11-13 10:25:55.014 24243-24323/com.cyberprologue.cp W/System.err: at java.lang.Thread.run(Thread.java:818)

11-13 10:25:55.017 24243-24323/com.cyberprologue.cp V/LoginAtivity: org.jivesoftware.smack.SmackException$NoResponseException: No response received within reply timeout. Timeout was 5000ms (~5s). Waited for response using: AndFilter: (AndFilter: (FromMatchesFilter (ignoreResourcepart): mytest@group.myserver.com, MessageTypeFilter: type=groupchat), org.jivesoftware.smackx.muc.MultiUserChat$6@eea73a7).

I have a feeling this might have to do with my server…can’t be sure. any quick input or is this a bug too? Thank you.

Fixed with Filter MUC ‘decline’ messages by type ‘normal’ · igniterealtime/Smack@54790cd · GitHub