【问题标题】:Play Install Referrer Library播放安装推荐人库
【发布时间】:2019-12-11 09:51:45
【问题描述】:

Google Play 开发者您好,

我们最近宣布将弃用 install_referrer 意图广播机制。由于您的一个或多个应用使用此意图来跟踪引荐,我们希望确保您在 2020 年 3 月 1 日之前进行切换。在此日期之后,新版本的 Play 商店应用将不再在应用安装后广播 install_referrer 意图。

需要操作

迁移到 Play Install Referrer API 以跟踪以下应用和/或游戏的应用安装情况。

  • 我最近收到了 Google 发来的这封电子邮件。
  • 我在我的 Android 应用程序中使用 Firebase Analytics 和崩溃报告来跟踪应用程序行为。
  • 开发人员文档主要突出显示正在使用我的应用程序中未使用的广告服务的应用程序。

对此的任何解决方案将不胜感激。提前致谢。

【问题讨论】:

  • 同样的问题,虽然我只使用 firebase 来推送通知
  • @MouaadAbdelghafourAITALI 请提供您纳入的任何解决方案。
  • 这个solution 可以帮助你
  • @MouaadAbdelghafourAITALI 感谢您的解决方案。我会调查的。

标签: android admob google-play-services


【解决方案1】:

如果您使用的是用于 Firebase Analytics 的 firebase-core SDK,请将其移除并排除 play-services measure sdk。

根据Firebase SDK release notes

No longer add the Android library com.google.firebase:firebase-core.
This SDK included the Firebase SDK for Google Analytics. 
Now, to use Analytics (or any of the Firebase products that require or recommend the use of Analytics), 
you need to explicitly add the Analytics dependency:

implementation ("com.google.firebase:firebase-analytics:17.2.1"){
    exclude group: 'com.google.android.gms', module: 'play-services-measurement'
    exclude group: 'com.google.android.gms', module: 'play-services-measurement-sdk'
    exclude group: 'com.google.android.gms', module: 'play-services-measurement-impl'
}

这可能会解决您的问题。

【讨论】:

  • 感谢@Unnati,它已被删除,但在以Caused by: java.lang.ClassNotFoundException: Didn't find class "com.google.android.gms.measurement.AppMeasurement"运行应用程序后出现错误
【解决方案2】:

就我而言,我在合并的清单文件中发现此来源的使用情况:“play-services-measurement:17.2.0”,其中包括权限 BIND_GET_INSTALL_REFERRER_SERVICE,这是导致问题的原因。 为了解决这个问题,我们可以明确排除不推荐使用的模块,这个修复对我有用:

implementation ("com.google.firebase:firebase-core:17.2.0"){
    exclude group: 'com.google.android.gms', module: 'play-services-measurement-api'
    exclude group: 'com.google.android.gms', module: 'play-services-measurement'
    exclude group: 'com.google.android.gms', module: 'play-services-measurement-sdk'
    exclude group: 'com.google.android.gms', module: 'play-services-measurement-impl'
    exclude group: 'com.google.android.gms', module: 'play-services-measurement-sdk-api'
    exclude group: 'com.google.android.gms', module: 'play-services-measurement-base'
}

为了测试,您可以检查在 gradle 同步后最终合并的清单文件中是否仍然存在权限 BIND_GET_INSTALL_REFERRER_SERVICE

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2011-05-04
    • 2017-07-15
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2020-07-22
    • 1970-01-01
    相关资源
    最近更新 更多