quickblox-ios-sdk icon indicating copy to clipboard operation
quickblox-ios-sdk copied to clipboard

Quick blox chat The operation couldn’t be completed. com.quickblox.chat error -1004

Open MohanNB opened this issue 1 year ago • 1 comments

** "[ChatStorage] dialog.join error: The operation couldn’t be completed. (com.quickblox.chat error -1004.)"

"[ChatViewController] dialog.join error: The operation couldn’t be completed. (forbidden error 403.)"

"[ChatStorage] dialog.join error: Cannot create/join room when already creating/joining/joined." t**

  • [ ] I have read the Documentation
  • [ ] I have searched for a similar issue in the project and found none

Environment details

Info Value
iOS Version e.g. 13.0 above
Quickblox iOS SDK version e.g. 2.17.11
Xcode Version e.g. Xcode 12.1
Repro with our demo sample e.g. does it happen with our demo sample?

Did this work before? yes

Expected behavior

"[ChatStorage] dialog.join error: The operation couldn’t be completed. (com.quickblox.chat error -1004.)"

"[ChatViewController] dialog.join error: The operation couldn’t be completed. (forbidden error 403.)"

"[ChatStorage] dialog.join error: Cannot create/join room when already creating/joining/joined."

While join the group chat getting empty chat history or not able join on dialogs .

Actual behavior

Used code before join group 👍

QBChat.instance.addDelegate(self) chatManager.delegate = self if QBChat.instance.isConnected == false { self.chatManager.connect() } self.chatManager.updateStorage()

self.dialogs = self.chatManager.storage.dialogsSortByUpdatedAt()

some time getting empty response : self.dialogs

**"[ChatStorage] dialog.join error: The operation couldn’t be completed. (com.quickblox.chat error -1004.)"

"[ChatViewController] dialog.join error: The operation couldn’t be completed. (forbidden error 403.)"

"[ChatStorage] dialog.join error: Cannot create/join room when already creating/joining/joined."**

USED CODE getting failed some dialogs list :

func chatManager(_ chatManager: ChatManager, didUpdateChatDialog chatDialog: QBChatDialog) {

// reloadContent(false)

    dialogs = chatManager.storage.dialogsSortByUpdatedAt()
    SVProgressHUD.dismiss()
}

func chatManager(_ chatManager: ChatManager, didFailUpdateStorage message: String) {
    //SVProgressHUD.showError(withStatus: message)
    vsprint("ERROR QBLOK Update Storage ===== ")
}

func chatManager(_ chatManager: ChatManager, didUpdateStorage message: String) {

// reloadContent(false) dialogs = chatManager.storage.dialogsSortByUpdatedAt() vsprint("didUpdateStorage chatDialog ===== (dialogs.count)") SVProgressHUD.dismiss() }

To enable full logs use the following code: yes I'm following it

[QBSettings setLogLevel:QBLogLevelDebug]; [QBSettings enableXMPPLogging];

MohanNB avatar Aug 24 '22 11:08 MohanNB

Hello, please check if the issue is reproduced on our samples https://docs.quickblox.com/docs/code-samples#chat-samples

ghost avatar Aug 31 '22 13:08 ghost