Paul King
Paul King

Reputation: 2011

"[Crashlytics:Crash] Reporting is disabled"

I am getting the following error messages when our production iOS app initializes:

[Crashlytics] Version 3.8.4 (121)
[Crashlytics] Running on iOS Simulator (iPhone), 10.3.0 (16E195) 
[Crashlytics:Crash] Reporting is disabled 
[Crashlytics] Crash reporting could not be initialized 
[Answers] Initialized 
[Fabric] Initialized with kit versions: {
    "com.twitter.answers.ios" = "1.3.4"; 
    "com.twitter.crashlytics.ios" = "3.8.4"; 
    "io.fabric.sdk.ios" = "1.6.11"; 
}

Every subsequent call to log an event gets the following error:

[Crashlytics:Crash] WARNING: CLSLog has been used before (or concurrently with) 
    Crashlytics initialization and cannot be recorded. The message was: ...

The non-production versions of the app work fine running the exact same code but with different bundleIDs. Normally when the app initializes for the first time, then I see the app populate in the Fabric dashboard, but in this case the app is not showing up.

We have an Android and an iOS version of the app, and they both use the same bundleID, so I am wondering if there is a conflict because of that? I see the Android version of the app in the dashboard, and it seems to be working properly. This is an app that originally was a Xamarin app that compiled to both platforms, neither of which incorporated Fabric/Crashlytics. We have now written native apps on each platform, and both are using Fabric/Crashlytics.

Since this is a pre-existing app in both stores, we do not have the option of changing either app’s bundleID.

Upvotes: 6

Views: 3358

Answers (4)

Tim Shadel
Tim Shadel

Reputation: 1517

When I finally traced it down in my situation, the error was entirely correct, but not obvious.

I saw these errors in various testing targets where the code we tested was using a custom logging wrapper which called CLSNSLogv(), but the test didn't actually go through the AppDelegate and therefore did NOT initialize Crashlytics. After trying a few things I was convinced that it worked when executed as an app, but in our configuration it was not working under the unit test configuration.

I'll likely alter our custom wrapper to bypass CLSNSLogv() during testing anyway. The biggest benefit of using that is when crashes occur on devices, so we won't be missing anything.

Upvotes: 0

Paul King
Paul King

Reputation: 2011

There are apparently cases where Crashlytics does not auto-activate new apps so that they show up under your list of apps, even though everything is coded correctly and data is going to their servers. In this case, send an email to Crashlytics support ([email protected]) that contains a copy of the info.plist entries for the app in question and they will activate it for you. I have had to do this several times, especially with app extensions.

Upvotes: 2

earnshavian
earnshavian

Reputation: 1864

One step I routinely miss is to make sure you've added the build phase on your target:

"${PODS_ROOT}/Fabric/run" ${FABRIC_API_KEY} ${FABRIC_BUILD_SECRET}

and either replace ${FABRIC_API_KEY} and ${FABRIC_BUILD_SECRET} with your key and secret or add custom build settings for each.

Upvotes: 3

JAL
JAL

Reputation: 42489

Make sure you initialize Crashlytics with Fabric before calling any Crashlytics methods:

Fabric.with([Crashlytics.self])

Upvotes: 4

Related Questions