Skip to content

Crash FABException / FirebaseApp.configure() (only on production builds) #5473

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
APPS2CREATE opened this issue Apr 27, 2020 · 7 comments
Closed

Comments

@APPS2CREATE
Copy link

[REQUIRED] Step 1: Describe your environment

  • Xcode version: 11.3.1
  • Firebase SDK version: 6.23.0
  • Firebase Component: Firebase/Crashlytics AND Crashlytics 3.14.0 (Auth, Core, Database, Firestore, Messaging, Storage, etc)
  • Component version: 6.23.0
  • Installation method: CocoaPods

[REQUIRED] Step 2: Describe the problem

Today I've started on the firebase integration for our tvOS apps. I had some problems with integrating our topshelf extension, but then found another thread (#5126) which stated the extension needed to use the same GoogleService-Info.plist as the main app.

Finally I've got it managed to make it work on my device with running the debug version from xcode itself on the device. After succeeding I made a release version to testflight, but after installing, when I want to open the app, it opens for 1 second and then crashes. (Seems it crashes on FirebaseApp.configure())

I'm not sure if I have done anything wrong or if it's a bug.

Steps to reproduce:

What I've done:
Followed the basic integration documentation of firebase.

  • New project
  • New App with id of the main target (main app)
  • Implemented the SDK
  • FirebaseApp.configure() in didFinishLaunch (AppDelegate + import Firebase)
  • Run script "${PODS_ROOT}/FirebaseCrashlytics/run" with 2 input filed for DSYM and path to the info.plist.

When running the app via Xcode on a real device it worked fine.
Debug app has 2 bundle id's
main app: com.company.mainApp.debug
extension: com.company.mainApp.debug.extension

For the release build I did the same steps, but just removed the debug GoogleService-Info.plist and replaced them with the release GoogleService-Info.plist. (This will later be a early stage run script, which will provide the correct one, but for testing now I've manually replaced them)

Release app also has 2 bundle id's (main tvOS app + topshelf)
main app: com.company.mainApp
extension: com.company.mainApp.extension

Both use in both debug/release cases the same GoogleService-info.plist (added to the correct target etc)

Since I can't attach xcode on the device because the app crashes immediately after installing from testflight I don't have any logs from xcode.

Logs from console:

*** Terminating app due to uncaught exception 'FABException', reason: '[Fabric] Value of Info.plist key "Fabric" must be a NSDictionary.'
*** First throw call stack:
(0x1afefce14 0x1af8068d0 0x1afdf382c 0x100e9b2e0 0x100e9aeb4 0x100e9aff8 0x100e68dd8 0x100e72ff0 0x100e726e0 0x100e687c4 0x1af8d0338 0x1af8d195c 0x100e68554 0x100e68970 0x101e4ca94 0x1af8d0338 0x1af8d195c 0x101e4c888 0x101e4e6b0 0x101e4e408 0x1b085fba4 0x1afe593b0 0x1afe593f8 0x1afe58758 0x1afe58410 0x1afdd4aec 0x1afe57d60 0x1b0837108 0x100ea91dc 0x100ea8374 0x100ea7fb8 0x100ea7f20 0x100da5554 0x100da4a28 0x1d2d453a8 0x1d2d47094 0x1d2d4c70c 0x1d260a400 0x1d2a104ec 0x1d260af14 0x1d260a940 0x1d260ad28 0x1d260a5d0 0x1d260eac8 0x1d29467fc 0x1d2a299f4 0x1d260e848 0x1d2a298f0 0x1d260e6b4 0x1d248f3c0 0x1d248df28 0x1d248f0f8 0x1d2d4ab34 0x1d2966f50 0x1b2834bb0 0x1b2859988 0x1b283f314 0x1b2859644 0x1af8d0338 0x1af8d2f90 0x1b287e568 0x1b287e234 0x1b287e75c 0x1afe7aeec 0x1afe7ae44 0x1afe7a5dc 0x1afe75728 0x1afe74fc8 0x1b2342328 0x1d2d4e8b0 0x100b54<…>

I've checked my Info.plist files and I don't have any Fabric key set anymore

@google-oss-bot

This comment has been minimized.

@maksymmalyhin
Copy link
Contributor

Looks like the exception is coming from the deprecated Fabric SDK. Could you make sure you remove Fabric SDK from your dependencies and check if you still have the issue?

@APPS2CREATE
Copy link
Author

@maksymmalyhin I've already removed the fabric from my podfile - deintegrated the pod and reinstalled everything. If I check my Podfile.lock it seems it's still there indeed, so I will check to remove this.

But it also seems it's there because of the old Crashlytics SDK (not the Firebase/Crashlytics). But If i remove this one, the app complains about the Crashlytics SDK not found anymore while it never gets called, so I supposed it was still necessary to use for the Firebase SDK?

I'll already check if I can remove the Fabric dependency in the mean time.

@APPS2CREATE
Copy link
Author

Ok @maksymmalyhin Seems cocoapods didn't remove Crashlytics and Fabric from the "Other Linker Flags" in the build settings, so it was still searching for these frameworks while i removed them. Everything seems to work for now. I will make another production build to test the case and I'll keep you up to date, thanks for the help already!

@morganchen12
Copy link
Contributor

If it's still crashing, can you symbolicate the stack trace and make sure you haven't accidentally linked Firebase twice?

@APPS2CREATE
Copy link
Author

@maksymmalyhin, @morganchen12 Crash is solved for me! Thanks for the quick help!

@maksymmalyhin
Copy link
Contributor

Happy to help!

@firebase firebase locked and limited conversation to collaborators May 28, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants