firebase / firebase-unity-sdk

The Firebase SDK for Unity
http://firebase.google.com
Apache License 2.0
209 stars 35 forks source link

[Bug] Revenue data not getting updated for iOS purchases on Google Analytics #464

Closed ap4996 closed 1 year ago

ap4996 commented 1 year ago

[REQUIRED] Please fill in the following fields:

[REQUIRED] Please describe the issue here:

(Please list the full steps to reproduce the issue. Include device logs, Unity logs, and stack traces if available.)

The revenue generated from IAPs in our iOS game isn't getting recorded on Google Analytics. It has been almost a year since it stopped recording properly. We have tried manually triggering the in_app_purchase event also for iOS, but no change in the data.

Steps to reproduce:

Have you been able to reproduce this issue with just the Firebase Unity quickstarts (this GitHub project)? What's the issue repro rate? (eg 100%, 1/5 etc) This is happening with all the iOS IAPs.

What happened? How can we make the problem occur? Purchases are working on iOS for our app but there is no revenue data being recorded for the same.

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:

We have tried to trigger a separate event for this as well and mark it as a conversion. The event gets triggered but there is no revenue data for the same.

This code that we wrote to manually trigger the event:

#if UNITY_IOS
        AppHelper.SendFirebaseTracker("in_app_purchase", new Firebase.Analytics.Parameter[] { 
            new Firebase.Analytics.Parameter("product_id", product.definition.id),
            new Firebase.Analytics.Parameter("value", Convert.ToInt64(product.metadata.localizedPrice)),
            new Firebase.Analytics.Parameter("quantity", 1),
            new Firebase.Analytics.Parameter("price", Convert.ToInt64(product.metadata.localizedPrice)),
            new Firebase.Analytics.Parameter("currency", product.metadata.isoCurrencyCode)
        });
        AppHelper.SendFirebaseTracker("in_app_ios", new Firebase.Analytics.Parameter[] { 
            new Firebase.Analytics.Parameter("product_id", product.definition.id),
            new Firebase.Analytics.Parameter("value", Convert.ToInt64(product.metadata.localizedPrice)),
            new Firebase.Analytics.Parameter("quantity", 1),
            new Firebase.Analytics.Parameter("price", Convert.ToInt64(product.metadata.localizedPrice)),
            new Firebase.Analytics.Parameter("currency", product.metadata.isoCurrencyCode)
        });
#endif
// TODO(you): code here to reproduce the problem
paulinon commented 1 year ago

Hi @ap4996,

Could you verify if version 9.5.0 produces the same issue? If so, kindly provide a minimal, reproducible example along with the logs returned after the events have been triggered so that we can analyze what's causing this behavior.

google-oss-bot commented 1 year ago

Hey @ap4996. 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!

ap4996 commented 1 year ago

Hey @paulinon , sorry for the delay. Our team is still trying to get the update out with version 9.5.0. I will update as soon as that is done. Thank you.

google-oss-bot commented 1 year ago

Hey @ap4996. 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!

ap4996 commented 1 year ago

So, we updated the Firebase version to 9.5.0 but still no revenue data for iOS. I will provide you with as much information from our side as possible in a couple of days.

google-oss-bot commented 1 year ago

Hey @ap4996. 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 1 year ago

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

@ap4996 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.