crisp-im / crisp-sdk-ios

:package: Crisp iOS SDK, add a chat in any iOS app and communicate with your users.
https://docs.crisp.chat/guides/chatbox-sdks/ios-sdk/
Other
43 stars 18 forks source link

Hidden Crash #27

Closed floriangbh closed 3 years ago

floriangbh commented 3 years ago

Hello,

We are running Crisp 1.03 and got this crash :

Crashed: com.apple.main-thread
0  Crisp                          0x10511699c _hidden#7195_ + 35 (__hidden#1194_:35)
1  Crisp                          0x105050950 _hidden#7191_ + 252 (__hidden#7317_:252)
2  Crisp                          0x10504e794 _hidden#7170_ + 234 (__hidden#7317_:234)
3  Crisp                          0x10504e230 _hidden#7169_ + 97 (__hidden#7317_:97)
4  Crisp                          0x10504efb4 _hidden#7178_ + 4377145268 (__hidden#1194_:4377145268)
5  Crisp                          0x1050fe22c _hidden#8869_ + 177 (__hidden#15907_:177)
6  Crisp                          0x105076cb0 _hidden#2930_ + 98 (__hidden#9220_:98)
7  Crisp                          0x104ffc51c _hidden#2779_ + 4376806684 (__hidden#3204_:4376806684)
8  Crisp                          0x104ffc654 _hidden#2780_ + 4376806996 (__hidden#1194_:4376806996)
9  Crisp                          0x1050d086c _hidden#13690_ + 4377675884 (__hidden#1194_:4377675884)

My DSyms are correctly upload.

Any idea how to fix it ?

Thanks

baptistejamin commented 3 years ago

You don’t have additional details?

Baptiste Jamin CEO, Crisp https://crisp.im/ - Connect your customers to your team.

On 27 Sep 2020, at 08:30, Florian Gabach notifications@github.com wrote:

Hello,

We are running Crisp 1.03 and got this crash :

Crashed: com.apple.main-thread 0 Crisp 0x10511699c hidden#7195 + 35 (hidden#1194_:35) 1 Crisp 0x105050950 hidden#7191 + 252 (_hidden#7317:252) 2 Crisp 0x10504e794 hidden#7170 + 234 (hidden#7317_:234) 3 Crisp 0x10504e230 hidden#7169 + 97 (hidden#7317_:97) 4 Crisp 0x10504efb4 hidden#7178 + 4377145268 (_hidden#1194:4377145268) 5 Crisp 0x1050fe22c hidden#8869 + 177 (hidden#15907_:177) 6 Crisp 0x105076cb0 hidden#2930 + 98 (hidden#9220_:98) 7 Crisp 0x104ffc51c hidden#2779 + 4376806684 (_hidden#3204:4376806684) 8 Crisp 0x104ffc654 hidden#2780 + 4376806996 (hidden#1194_:4376806996) 9 Crisp 0x1050d086c hidden#13690 + 4377675884 (_hidden#1194:4377675884) My DSyms are correctly upload.

Any idea how to fix it ?

Thanks

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/crisp-im/crisp-sdk-ios/issues/27, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAGTRQ4VHBLTSEE6I2P5DSTSH3LY7ANCNFSM4R3LY6UA.

floriangbh commented 3 years ago

Unfortunately no, it seems to happen when presenting the chat.

    func presentChat(from: UIViewController) {
        CrispSDK.session.setString("iOS", forKey: "source")
        CrispSDK.session.setString(Bundle.main.displayName ?? "Unknown", forKey: "app")

        DispatchQueue.main.async {
            from.present(ChatViewController(), animated: true)
        }
    }
Arthur-Guillaume commented 3 years ago

I have the same issue, does anyone have a clue ? On my side, it seems to happen when setting user info.

CrispSDK.user.email = user?.email
CrispSDK.user.nickname = user?.getUsername()
ionutteslovan commented 3 years ago

Same issue here. It crashes when creating the ChatViewController. I can reproduce this at all times with a physical device running iOS 14.1. (it also did happen with iOS 14). Tried all versions from 1.0.2 to 1.0.5 and the crash is always there. Seems to be an iOS 14 issue. Worth to mention that the crash is not present if run on a simulator. (even on >= iOS 14)

Arthur-Guillaume commented 3 years ago

@baptistejamin This crash is the one occurring the most in production in my app. Do you have any clue ?

If you need any further details, let us know what we can do to help you solve this issue.

JMCPH commented 3 years ago

We are experiencing the same issue.

Please let us know if you need any further information @baptistejamin.


0  Crisp                          0x103a3e99c _hidden#7195_ + 35 (__hidden#1194_:35)
1  Crisp                          0x103978950 _hidden#7191_ + 252 (__hidden#7317_:252)
2  Crisp                          0x103976794 _hidden#7170_ + 234 (__hidden#7317_:234)
3  Crisp                          0x103976230 _hidden#7169_ + 97 (__hidden#7317_:97)
4  Crisp                          0x103976fb4 _hidden#7178_ + 4345442228 (__hidden#1194_:4345442228)
5  Crisp                          0x103a2622c _hidden#8869_ + 177 (__hidden#15907_:177)
6  Crisp                          0x10399ecb0 _hidden#2930_ + 98 (__hidden#9220_:98)
7  Crisp                          0x10392451c _hidden#2779_ + 4345103644 (__hidden#3204_:4345103644)
8  Crisp                          0x103924654 _hidden#2780_ + 4345103956 (__hidden#1194_:4345103956)
9  Crisp                          0x1039f886c _hidden#13690_ + 4345972844 (__hidden#1194_:4345972844)
10 app                          0x1031b19bc protocol witness for MyProfileRoutingLogic.routeToSupport() in conformance MyProfileRouter + 93 (MyProfileRouter.swift:93)
11 app                          0x10317c4c0 MyProfileViewController.tableView(_:didSelectRowAt:) + 313 (MyProfileViewController.swift:313)
12 app                          0x10317cf3c @objc MyProfileViewController.tableView(_:didSelectRowAt:) + 4337143612 (<compiler-generated>:4337143612)
13 UIKitCore                      0x1a67eefd8 -[UITableView _selectRowAtIndexPath:animated:scrollPosition:notifyDelegate:isCellMultiSelect:] + 1096
14 UIKitCore                      0x1a67eeb78 -[UITableView _selectRowAtIndexPath:animated:scrollPosition:notifyDelegate:] + 108
15 UIKitCore                      0x1a67ef33c -[UITableView _userSelectRowAtPendingSelectionIndexPath:] + 268
16 UIKitCore                      0x1a6a9d95c -[_UIAfterCACommitBlock run] + 64
17 UIKitCore                      0x1a660779c _runAfterCACommitDeferredBlocks + 296
18 UIKitCore                      0x1a65f6b4c _cleanUpAfterCAFlushAndRunDeferredBlocks + 200
19 UIKitCore                      0x1a6628260 _afterCACommitHandler + 76
20 CoreFoundation                 0x1a3d37ecc __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 32
21 CoreFoundation                 0x1a3d325b0 __CFRunLoopDoObservers + 604
22 CoreFoundation                 0x1a3d32af8 __CFRunLoopRun + 960
23 CoreFoundation                 0x1a3d32200 CFRunLoopRunSpecific + 572
24 GraphicsServices               0x1b9e2d598 GSEventRunModal + 160
25 UIKitCore                      0x1a65f8004 -[UIApplication _run] + 1052
26 UIKitCore                      0x1a65fd5d8 UIApplicationMain + 164
27 app                          0x102ffea60 main + 24 (SignupRouter.swift:24)
28 libdyld.dylib                  0x1a3a11598 start + 4```
trevinwisaksana commented 3 years ago

Hi,

I don't know if this is the same issue. But here is one place where Crisp seem to be crashing.

Screen Shot 2020-11-05 at 17 15 37
JMCPH commented 3 years ago

@baptistejamin can you please take a look and give us an update on this?

We are a paying customer, and it's extremely frustrating for our users that this crash is occurring.

ionutteslovan commented 3 years ago

Any news about this?

nesium commented 3 years ago

We've just release version 1.0.6 which hopefully addresses this issue. Could you please try again with that version and let us know if you're still encountering the problem?

ionutteslovan commented 3 years ago

Thank you! 1.0.6 does fix the crash, but the chat still doesn't work on > iOS 14. (on older versions of iOS it works fine) It's stuck at "Starting chat..." and this is the error from the console: [error] Could not create URL from string 'https://settings.crisp.chat/client/website//WEBSITE_ID/prelude/?2020-11-18-9-12 AM'. Please report this to https://github.com/crisp-im/crisp-sdk-ios/issues/new and quote this message there.

nesium commented 3 years ago

@ionutteslovan Can you please check if you have configured the Crisp SDK correctly, as decribed here. E.g.

CrispSDK.configure(websiteID: "make-sure-this-is-correct")
ionutteslovan commented 3 years ago

@nesium Yes, it's configured correctly. As I was saying it works fine on any device/simulator with a different version than ios 14.

nesium commented 3 years ago

@ionutteslovan Thanks for checking. I cannot reproduce this neither on a device nor on a simulator running iOS 14.2. I'm assuming that you cannot send me your project, but is there a chance that you can reproduce this in a small sample project?

nesium commented 3 years ago

Hi @ionutteslovan. The problem is fixed in 1.0.8. Please let us know in case your still experiencing the problem after upgrading. Thank you!