Xamarin Forms Firebase Crashlytic Doesn't work on Android - android

Installed nuget
Xamarin.Firebase.Crashlytics 117.3.0
Code i call in Android project:
FirebaseCrashlytics.Instance.SetUserId("someid");
FirebaseCrashlytics.Instance.SetCrashlyticsCollectionEnabled(true);
FirebaseCrashlytics.Instance.SetCustomKey("MyKey", "MyValue");
FirebaseCrashlytics.Instance.Log("Testing log crashlytic");
FirebaseCrashlytics.Instance.SendUnsentReports();
Code i call in Xamarin Forms
throw new Exception("Test crashlytic");
And i still get this on my firebase console
I also wait for a few hour incase it delayed, but its still doesnt work
I also installed Firebase Analytic and it works fine
Implementation that i followed
another stackoverflow answer

Related

React-Native Headless task not working on android

I'm using sample code available on connecty-cube GitHub repo. When I call to user who is on android phone doesn't receive the notification for call when app is in background. And when app is open user can see the incoming call. Constructor of PushNotificationsService run and I can see this console [PushNotificationsService][constructor]. But inside _registerBackgroundTasks() function [JSNotifyWhenKilledTask] notificationBundle console doesn't run. I do get UDID for channels APNS, APNS VOIP and UDID for channel FCM in connecty cube dashboard.
So that's how I figured out the problem.
Make sure you have properly configured each step of every required library for connecty-cube.
Follow the docs
After that I checked sdk version of firebase on firebase console.
It stated classpath 'com.google.gms:google-services:4.3.13' in (<project>/build.gradle). But mine was classpath 'com.google.gms:google-services:4.3.10'. And because of that notification was not appearing. Now it's works.
I assume you are referring https://github.com/ConnectyCube/connectycube-reactnative-samples/tree/master/RNVideoChat
I suggest the following:
follow Getting started guide https://github.com/ConnectyCube/connectycube-reactnative-samples/tree/master/RNVideoChat#getting-started and make sure you have google-services.json properly located
Re-check https://developers.connectycube.com/reactnative/videocalling?id=receive-call-request-in-backgroundkilled-state where it describes how BG task works

Firebase push notification - Default FirebaseApp is not initialized in this process

I am struggling to implement Google's Firebase push notifications in a mature MVVMcross application. We are being forced to seek a new solution to our current one because it appears that the functionality is about to be deprecated in AppCenter.
We've placed the code inside the RootActivity file (at the bottom of the method)
protected override void OnCreate(Bundle bundle)
When I run the app in a USB/debug scenario on my Android Galaxy I get the current error "Default FirebaseApp is not initialized in this process"
I tried to use the approach that was recommended in the error message to no avail:
FirebaseApp.InitializeApp(RootActivity.Context);
FirebaseMessaging.Instance.GetToken().AddOnCompleteListener(new OnCompleteListener());
In case anyone is wondering here is the code for the method that is mentioned above was setup for testing purposes using a breakpoint:
public class OnCompleteListener : Java.Lang.Object, IOnCompleteListener
{
public void OnComplete(Android.Gms.Tasks.Task task)
{
var token = task.Result.ToString();
}
}
We initially tested this in a standard Xamarin Forms Android app for testing and didn't have any problem with getting the token but we hit the wall when we played with it in our client's MVVMcross app.
I would also like to mention that I have tried the following solution with no luck as well:
var setupSingleton = MvxAndroidSetupSingleton.EnsureSingletonAvailable(Context);
setupSingleton.EnsureInitialized();
FirebaseMessaging.Instance.GetToken().AddOnCompleteListener(new OnCompleteListener());
I found that I had two problems. The first one was the fact that my project name did not match in my manifest and google services key. I was using my own key that I setup for testing. After I realized this I switched back to my client's key and double checked that it was part of the build. As soon as I resolved that issue I found that I needed to install the nuget package for Xamarin.Google.Dagger to resolve the reflection issues. After taking care of that I did a clean/rebuild and ran the debug on my Galaxy S20 test device. This fix allowed me to hit my test break point that I setup for testing the token reception from FCM.

Configure Multiple Firebase Projects Runtime in iOS application and Firebase/Google Analytics

We are starting to migrate from Google Analytics to Firebase Analytics as it is going to be deprecated in a year. We have a need of initializing the firebase project runtime in our iOS application and we are following the steps mentioned here: https://firebase.google.com/docs/projects/multiprojects?authuser=0
Why do we need to initialize the firebase manually and at runtime? The details are in this issue: Switching between different firebase projects (runtime) in one single APK file
I posted that issue when we encountered a similar problem for push notifications on Android because at that time the documentation was not sufficient. It is really good to know that firebase documentation has been updated to reflect how to manually initialize the sdk for various platforms.
Problem: The problem that we are facing today is that once we initialize the SDK manually for say a "secondary" application and we try to use the firebase analytics, it fails with following error:
2018-12-20 17:14:33.526757-0800 App Name[9218:675367] 5.2.0 - [Firebase/Analytics][I-ACS025018] Event not logged. Call +[FIRApp configure]: AppLaunch
Below is the sample piece of code:
FIROptions *firoptions = [[FIROptions alloc] initWithGoogleAppID:#"Actual_GoogleAppId" GCMSenderID:#"Actual_GCMSenderId"];
firoptions.bundleID = #"actual.bundle.id";
firoptions.APIKey = #"actual-api-key";
firoptions.clientID = #"actual.client.id";
firoptions.databaseURL = #"https://actual.url";
firoptions.storageBucket = #"actualapp.appspot.com";
[FIRApp configureWithName:#"testApp" options:firoptions];
if ([FIRApp appNamed:#"testApp"]) {
[FIRAnalytics logEventWithName:#"AppLaunch" parameters:nil];
}
Looking at the error it tells us to use [FIRApp configure] which configures the default application from the GoogleService-Info.plist in the project. But we do not have GoogleService-Info.plist in our project as suggested in https://firebase.google.com/docs/projects/multiprojects?authuser=0.
TL;DR: We are initializing the firebase app manually in our iOS application using the API [FIRApp configureWithName:#"testApp" options:firoptions]; and the Firebase Analytics gives an error asking us to use default [FIRApp configure] which defeats the purpose of manual initialization.
Any help is greatly appreciated.
Firebase Analytics requires the file to be named GoogleService-Info.plist. Note the first paragraph of https://firebase.google.com/docs/projects/multiprojects?authuser=0 recommends differentiating multiple versions of it by putting them in different directories.
More details about FirebaseAnalytics and multiple plist files at https://github.com/firebase/firebase-ios-sdk/issues/230

Why integrated fabric(crashlytics) with gitlab does not send issues to gitlab?

I use fabric-Crashlytics in my android app and initiate it in Application class via
Fabric.with(new Fabric.Builder(this)
.kits(new Crashlytics(), new Answers())
.debuggable(true)
.build()
);
I integrated fabric with gitlab in fabric's service hooks successfully, It means when I press "Send Test" blue button on fabric I'll receive an issue in gitlab.
BUT when I force app to crash via [Crashlytics.getInstance().crash();] ,I don't get any issue in gitlab, Why?
How Can I fix this problem?
My problem solved as I said in comments.Thanks MikeBonnell for the comment:
Mike from Fabric here. What impact level did you choose on the integration? Only if the impact level was set to 1 would a new issue be triggered. Also, this needs to be a brand new issue, that is if you've used that test crash before, then a new issue wouldn't be sent over.

how to fix ["failed to register ","Device does not have package com.google.android.gsf"]

I am new to phonegap and I want to implement pushwoosh notification services but I cant get it right. Every time I call the registerPushwoosh() function I get this error.
I am using the SDK Sample Project -> Android Phonegap.
every time getting this error.
how to fix ["failed to register ","Device does not have package com.google.android.gsf"]
here is image link ERROR AND DIrectory
You need to use Emulator with a Google API.

Categories

Resources