dji-sdk / Mobile-SDK-iOS

DJI Mobile SDK for iOS: http://developer.dji.com/mobile-sdk/
Other
576 stars 254 forks source link

Firebase Crashlytics not working with DJI SDK #368

Open BDProject opened 4 years ago

BDProject commented 4 years ago

Hello,

I've added Firebase Crashlytics to my project. It will track and upload crashes if they happen before the point, that the DJI SDK is initialized in my app. But once DJI SDK is working in the app, none of the crashes are uploaded. Does the DJI iOS SDK have its own crash logging, which is catching all crashes once the DJI code starts to run inside an app?

So in short: My app logs crashes if they happen before I call [DJISDKManager registerAppWithDelegate:self]; [DJISDKManager startConnectionToProduct]; After that, something else seems to intercept them and I don't get to upload the crashs to Firebase Crashlytics.

Can you guys advise what is going on, please?

Many Thanks, B

dji-dev commented 4 years ago

Agent comment from Luce Luo in Zendesk ticket #35249:

Dear Customer,

Thank you for contacting DJI. Sorry the MSDK doesn't have its own log mechanism for the developer. You can add your own mechanism or contact us via the form if any crash hitting.

If the Firebase Crashlytics not work, please fill in the form with more detail about how we can reproduce it. https://formcrafts.com/a/dji-developer-feedback-en

Thanks,

Luce Luo DJI Dev Team

BDProject commented 4 years ago

I have an update for you guys. I've been attempting to debug this further. So I changed from Firebase Crashlytics to the Sentry.io service. I tested it in a demo iOS app, setup was easy and it logged crashes. I moved it to the app using the DJI SDK and it exhibits the same problem as Firebase Crashlytics where the DJI SDK is seemingly catching crashes as they never appear in the app past the point where I initialize the DJI Mobile SDK.

BDProject commented 4 years ago

One of the devs from Firebase team suggested "I don't know much about the DJI SDK, but it does sound like it's doing something along the lines of registering an exception handler of some sort (especially since you run into the same problems with Sentry), maybe even if it's not explicitly logging crashes. "