Closed devperson closed 2 years ago
@devperson In order to use firebase-messaging 22 or higher you must use OneSignal-Android-SDK 4.4.0 or newer so I believe this is your issue. However we always recommend the latest version SDK.
After updating if you still see the issue please provide the updated error message and we an reopen this issue.
Hi @jkasten2, I am using the OneSignalSDK.Xamarin for Xamarin Forms so currently I am using the latest version(4.1.3) for XF. I fixed the issue by changing the notification body/content(json payload)
@devperson Good to hear you got it working! Very odd that the payload change would have any effect on the "Default FirebaseApp is not initialized in this process app" error.
When you did have the error, was it causing a crash or just you noticed it in the logcat?
Yes the app crashes. I got the StackTrace of the error from AppCenter
What happened?
I am getting the
com.google.firebase.FirebaseApp.getInstance java.lang.IllegalStateException: Default FirebaseApp is not initialized in this process app.utilla. Make sure to call FirebaseApp.initializeApp(Context) first
after a few seconds of the app launch, on my samsung galaxy s21 device. Here is the stacktrace:It seems this happens in the
logNotificationReceived
method of the MessagingAnalytics. I found relevant post in the StackOverflow: https://stackoverflow.com/questions/52169115/android-firebase-crash-in-messaginganalyticsSteps to reproduce?
What did you expect to happen?
app should work like on other devices without crash
OneSignal Android SDK version
Release 4.1.3
Android version
12
Specific Android models
Relevant log output
No response
Code of Conduct