Closed Nyankoo closed 4 weeks ago
Possibly related to this? https://github.com/firebase/firebase-android-sdk/issues/2158#issuecomment-732989095
@Nyankoo
This is odd. I don't think we provide InAppMessaging API in our Firebase Unity SDK. Are you using InAppMessaging in your app? If so, is your project directly use native Android SDK?
If not, the only possible reason is that one of those Firebase product you used, a.k.a Firestore, Analytics, Crashlytics, Remote Config
, is calling InAppMessaging API internally. Or perhaps Admob is using it. From the functionality of those products and InAppMessaging, it does not make too much sense though.
https://github.com/firebase/firebase-android-sdk/issues/2158#issuecomment-732989095 looks like an issue for Firebase Performance, which is not available in Unity SDK either. Also that is not related to InAppMessaging.
Could you provide a bit more information about how InAppMessaging got into your app?
Shawn
@chkuang-g Yes, we're using the native Android SDK directly by adding the correct dependencies through the External Dependency Manager.
@Nyankoo
Ah I see.
Currently Firebase Unity SDK does not fully support this use-case, that is mixed use of Android native SDK and Unity SDK. We do not test Unity SDK for such use at all so we cannot guarantee it works perfectly. Also it is hard for me to tell if this is an Android SDK issue or something related to the whole C++/Unity architecture. I'm most concerned about the life-cycle of the FirebaseApp instance from Android.
However, I recognize that some team would do so to access Firebase products which is not available in Unity SDK yet. I appreciate the enthusiasm! However, the safest way is to file a feature request ticket to Unity SDK team to properly support InAppMessaging. But I digress.
Let clarify several things first
7.1.0
Also, I would recommend you to open a ticket at firebase-android-sdk repo and point to this issue as a reference.
@chkuang-g Thank you for the detailed explanation!
Do I file a feature request directly here in this repo, or somewhere else?
About your questions:
public void messageClicked
event handler, we process deep-link information depending on which button of the message was tapped. More details about this can be found here: https://www.robinryf.com/blog/2020/01/04/firebase-in-app-message-in-unity.htmlAnother note that could be important is that we're getting the same debug output ("Starting InAppMessaging runtime...") on our test devices as mentioned in the Android documentation here: https://firebase.google.com/docs/in-app-messaging/get-started?authuser=0&platform=android#get_your_apps
Thank you for the information.
I'll forward this to the team.
Hi @Nyankoo, Do you know if your application is directly or transitively pulling in a version of protobuf libraries (protobuf-javalite or any other protobuf libraries) that is different from Firebase protobuf library version?
For FIAM 19.1.4, we are using 3.14.0.
| | +--- com.google.firebase:protolite-well-known-types:17.1.1
| | | \--- com.google.protobuf:protobuf-javalite:3.14.0
@vimanyu Is there a way to check this somewhere in the final .aab file (or somewhere else)?
If you are using gradle for your application, you could run the following to get list of dependencies.
# assuming app is the name of the project
./gradlew app:dependencies
@vimanyu These are the dependencies I could find, added by the Firestore and In-App Messaging plugins:
com.google.protobuf:protobuf-javalite:3.14.0
io.grpc:grpc-protobuf-lite:1.28.0
com.google.protobuf:protobuf-javalite:3.11.0 -> 3.14.0
io.grpc:grpc-protobuf-lite:1.28.0 (*)
Great. So if you export your project to Android Studio project (using MainTemplate gradle) from Unity, you should be able to query all the dependencies being pulled in by the application. We are trying to see if there is any non-compatible version of protobuf libraries being introduced by any other package.
@vimanyu The above dependencies are the only ones I can see in the dependency tree after exporting to Android Studio.
Thanks for confirming. It does seem like something tried to get javalite 3.11.0 but was bumped up to 3.14.0. Another clarification, is the error 100% reproducible on the devices listed in the original post?
@vimanyu We sadly don't have any of the listed devices on hand to test this. The list comes directly from Crashlytics (user devices).
I couldn't figure out how to label this issue, so I've labeled it for a human to triage. Hang tight.
Moving this issue to firebase-android-sdk as this seems like something not caused by the C++/Unity layer. We haven't been able to reproduce this issue locally but we should keep an eye out for this just incase there are more occurrences. User pointed out it could be related to https://github.com/firebase/firebase-android-sdk/issues/2158 and I have confirmed that we are using the libraries with versions which should have the fix for that issue.
Something that could be related as per internal discussions is, b/169066309
Any update on this?
@vimanyu @aguatno
Hi @Nyankoo, unfortunately since it is not reproducible, it hasn't been prioritized yet. Are you running into it often? @var-const, have we seen this error being reported by users of Android SDK before?
@vimanyu I don't think we've seen this in Firestore -- adding @schmidt-sebastian Sebastian to confirm.
@vimanyu @var-const This happened to a majority of our users and we needed to pull the plug by disabling all In-App Messaging setups in the Firebase Dashboard. Since then, we didn't try again.
cc @gesly who works on In App Messaging
@vimanyu @var-const @schmidt-sebastian Any update on this?
[REQUIRED] Please fill in the following fields:
[REQUIRED] Please describe the issue here:
Some of our users getting crashes caused by the InAppMessaging package. When this is happening is currently unknown to us, as we can't replicate this on our end.
The devices the crashes happen on are:
Steps to reproduce:
Have you been able to reproduce this issue with just the Firebase Unity quickstarts (this GitHub project)?
What happened? How can we make the problem occur?
If you have a downloadable sample project that reproduces the bug you're reporting, you will likely receive a faster response on your issue.
Relevant Code: