xamarin / GoogleApisForiOSComponents

MIT License
225 stars 161 forks source link

Firebase Crashlytics implementation in Xamarin Forms. #449

Open PrasadCP opened 3 years ago

PrasadCP commented 3 years ago

Hi, I have a Xamarin form project in both iOS and Android. Customer needs to implement Firebase Crashlytics in both app. So I started implementing Firebase Crashlytics in Xamarin iOS and android project. I referred the following link([https://medium.com/@hakimgulamali88/firebase-crashlytics-with-xamarin-5421089bb561] for implementation. I completed all tasks as in that link. But still in Firebase console the status showing as ( Add the Firebase iOS SDK (4.3.0 or higher) or Unity Plugin (6.15.0 or higher), then build, run, and crash your app ).

Please give a solution for fixing this issue.

Or else please give a helpful link, for implementing in both Xamarin iOS and Xamarin Android.

Thanks, Prasad CP. Mob: 9496380738

mayhammf commented 3 years ago

@PrasadCP This is related to #436 The PR #445 is being tested/finalized by the team now and it will reference the latest Firebase libraries.

mayhammf commented 3 years ago

@PrasadCP As for Android, you can follow this excellent upgrade guide to upgrade from what you have based on the tutorial you mentioned.

padmasrisekar commented 3 years ago

Could anyone please provide the details, which version of Xamarin forms and Xamarin.iOS supports for firebase crashlytics update.

Thanks in Advance

theddy1337 commented 3 years ago

@padmasrisekar,

The PR #445 is merged and Xamarin.Firebase.iOS.Crashlytics 4.6.2 nuget is released

Dependencies are: Xamarin.iOS 1.0 Xamarin.Build.Download (>= 0.10.0) Xamarin.Firebase.iOS.Core (>= 6.10.4) Xamarin.Firebase.iOS.Installations (>= 1.7.0)

PrasadCP commented 3 years ago

@theddy1337 I updated the firebase to it's latest version. But the code like Crashlytics.Configure(); Crashlytics.SharedInstance.Crash();

are not supporting. Do we have any other replacements for this?

mayhammf commented 3 years ago

@PrasadCP Crashlytics.Configure(); is no longer needed. According the documentation of the native Crashlytics library https://firebase.google.com/docs/crashlytics/get-started

padmasrisekar commented 3 years ago

@padmasrisekar,

The PR #445 is merged and Xamarin.Firebase.iOS.Crashlytics 4.6.2 nuget is released

Dependencies are: Xamarin.iOS 1.0 Xamarin.Build.Download (>= 0.10.0) Xamarin.Firebase.iOS.Core (>= 6.10.4) Xamarin.Firebase.iOS.Installations (>= 1.7.0)

@theddy1337 are you sure xamarin.ios version is 1.0 because we are using xamarin.ios13.2 and xcode 11.2 but im getting error "native linking error". Any help or resolution would be great help!! Thanks in Advance.

jthegeman commented 3 years ago

I am receiving this error after upgrading:

//Users/{user}/{app}/{app-name}.iOS/MTOUCH: Error MT1303: Could not decompress the native framework 'FirebaseInstallations.framework' from '/Users/{user}/{app}/{app-name}.iOS/obj/iPhoneSimulator/Debug/mtouch-cache/FirebaseInstallations.framework.zip'. Please review the build log for more information from the native 'unzip' command. (MT1303) (PublicStorageMobile.iOS)

Process exited with code 2, command: /usr/bin/unzip System.String[] PrivateHeaders/: mismatching "local" filename (FirebaseInstallations), continuing with "central" filename version file #2: bad zipfile offset (local header sig): 73 file #3: bad zipfile offset (local header sig): 655 Archive: /Users/{user}/{app}/{app-name}.iOS/obj/iPhoneSimulator/Debug/mtouch-cache/FirebaseInstallations.framework.zip

jthegeman commented 3 years ago

Looks like the FirebaseInstallations.framework.zip is corrupted.

GoodGeoffrey commented 3 years ago

I have same problem like @jthegeman. Tryed some clearing (both win and mac), but without luck.