You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Play Console警告:需更新Play Core Maven依赖适配Android 14,求解决方案

解决Play Core依赖与Android 14不兼容的方案

核心解决步骤

  • 找到应用模块下的build.gradle(Groovy)或build.gradle.kts(Kotlin)文件,定位到dependencies代码块。
  • 替换或更新Play Core相关依赖到兼容Android 14的最新稳定版本:
    • 若使用传统全量Play Core库:
      // 旧版本
      implementation 'com.google.android.play:core:旧版本号'
      // 更新为兼容Android 14的版本(例如1.10.3及以上)
      implementation 'com.google.android.play:core:1.10.3'
      
      // Kotlin DSL旧版本
      implementation("com.google.android.play:core:旧版本号")
      // 更新为兼容版本
      implementation("com.google.android.play:core:1.10.3")
      
    • 若使用Google推荐的模块化Play Core库(按需引入功能模块):
      // 应用内更新模块示例
      implementation 'com.google.android.play:core-inapp-update:2.1.0'
      // 应用评论模块示例
      implementation 'com.google.android.play:core-review:2.0.1'
      
      // Kotlin DSL示例
      implementation("com.google.android.play:core-inapp-update:2.1.0")
      implementation("com.google.android.play:core-review:2.0.1")
      
  • 点击Android Studio顶部的「Sync Project with Gradle Files」按钮,同步项目依赖。
  • 确认应用的targetSdkVersion已设置为34,确保整体适配Android 14的要求。

额外注意事项

  • 若代码中存在自定义静态注册的隐式广播接收器,需按照Android 14规范调整(改为动态注册或使用显式广播),避免额外兼容性问题。
  • 同步完成后重新构建并测试应用,确认无依赖更新导致的崩溃或异常。

内容的提问来源于stack exchange,提问作者gtxtreme

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.06.22 03:12:37