firebase / firebase-android-sdk

Firebase Android SDK
https://firebase.google.com
Apache License 2.0
2.26k stars 573 forks source link

[FIAM] - Frequently getting `Successfully fetched 0 messages from backend` #5786

Closed niteshnarayan closed 5 months ago

niteshnarayan commented 6 months ago

[REQUIRED] Step 2: Describe your environment

Android Studio version: Android Studio Jellyfish | 2023.3.1 Canary 13 Build #AI-233.14475.28.2331.11543046, built on March 7, 2024

Emulator : Android 13 TE1A.220922.010 Device: Huawei Mate 20 Pro Android 12 Device: Samsung S23 Android 14

[REQUIRED] Step 3: Describe the problem

Hi, I have integrated FIAM as per the official documentation and would like In-App messages to be displayed on analytics events, but for some reason on app reinstall and also in general getting 0 messages from the backend. Occasionally the messages(I have multiple live campaigns and the correct number is displayed) show up and make it difficult to test. Any idea if I am missing something here? Logs below:

I have single Activity in which i have the SDK init:

  override fun onResume() {
        super.onResume()
        FirebaseApp.initializeApp(this)
        FirebaseInAppMessaging.getInstance().setMessageDisplayComponent(
            MessageDisplayComponent(baseContext)
        )
    }
google-oss-bot commented 6 months ago

I found a few problems with this issue:

lehcar09 commented 6 months ago

Hi @niteshnarayan , thank you for reaching out. I tried reproducing the issue, but I was unsuccessful. I was able to receive the message without an issue. Is there any chance you could provide an MCVE to help us investigate the issue? If you're unable to provide one, can you try our quickstart app and see if you can reproduce the issue?

Aside from that, I recommend migrating dependency from the main module instead of the KTX modules. KTX modules are now deprecated. As early as April 2024, we'll no longer release KTX modules, and we'll also remove the KTX libraries from the Firebase Android BoM at that time. You can check this documentation for more details.

niteshnarayan commented 6 months ago

Hi @lehcar09 thanks a lot for the reply. Unfortuantely i dont do anything extra apart from whatever already mentioned, so cant provide any MCVE. I will try to follow quick start guide and see if still having the issue. Thanks for the migration info!

lehcar09 commented 5 months ago

HI @niteshnarayan, I'll set the 'needs-info' tag for now. Let us know if the issue is resolved on your side. Please do keep in mind that our SDK support team do not have access to the backend or your project details. For us to verify if this is an SDK issue, we require steps to reproduce this behavior or a minimal reproducible example for us to conduct investigation on your issue.

google-oss-bot commented 5 months ago

Hey @niteshnarayan. We need more information to resolve this issue but there hasn't been an update in 5 weekdays. I'm marking the issue as stale and if there are no new updates in the next 5 days I will close it automatically.

If you have more information that will help us get to the bottom of this, just add a comment!

google-oss-bot commented 5 months ago

Since there haven't been any recent updates here, I am going to close this issue.

@niteshnarayan if you're still experiencing this problem and want to continue the discussion just leave a comment here and we are happy to re-open this.