Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

iOS: Crashlytics Crashing on Init

Tags:

In my AppDelegate, I call

[Fabric with:@[CrashlyticsKit]]; 

and everything works fine. Now I pulled my code onto another machine, and the same line gives me the following error:

*** Terminating app due to uncaught exception 'FabricException', reason: '[Fabric] Value of Info.plist key "Fabric" must be a NSDictionary.' 

I'm not aware of any additions in my project's plist. Any ideas what this error may be referring to and how to fix it?

like image 798
Maxwell Avatar asked May 28 '15 17:05

Maxwell


People also ask

Is Crashlytics real time?

Firebase Crashlytics is a lightweight, realtime crash reporter that helps you track, prioritize, and fix stability issues that erode your app quality. Crashlytics saves you troubleshooting time by intelligently grouping crashes and highlighting the circumstances that lead up to them.


2 Answers

Fabric automatically inserts of hunk of text into your application's plist when you install it. These are essential and Fabric throws an exception on initialisation if they're not present.

Unfortunately it doesn't actually tell you it does this, so we ran into this crash on a project where the plist was automatically generated by a tool - which overwrote what Fabric had added.

For reference, this is what the Fabric part of the plist looks like in the current version (not sure where the version number is, but the latest version as of 15th June 2015).

<key>Fabric</key> <dict>         <key>APIKey</key>         <string>your-api-key</string>         <key>Kits</key>         <array>                 <dict>                         <key>KitInfo</key>                         <dict/>                         <key>KitName</key>                         <string>Crashlytics</string>                 </dict>         </array> </dict> 
like image 119
JosephH Avatar answered Sep 17 '22 19:09

JosephH


One more way to solve this Using Fabric App.

  1. Launch Fabric app and log in with your user ID.
  2. Click on Add New App
  3. Select your .xcodeproj file and follow on screen instruction

Do not manually add Fabric key in your .info plist file

like image 29
UIResponder Avatar answered Sep 17 '22 19:09

UIResponder