首页 > 解决方案 > 如何解决“应用程序在使用 google play 服务时出现问题。请重试。”

问题描述

我已经在 react-native 中制作了一个项目大约 4 个月了,现在使用"react-native": "^0.57.4". 它由一个地图视图组成,我正在使用"react-native-maps": "^0.22.1".

突然我现在有这个错误 - "App" is having trouble with google play services. Please try again.

上面的错误显示了地图应该在哪里。地图组件是灰色的,"App" is having trouble with google play services. Please try again.上面写着信息。

我尝试在实际设备上运行它,它运行得非常好。所以这意味着它是一个模拟器问题。任何人都可以分享有关如何在模拟器上解决此问题的任何见解或解决方案吗?

我正在使用带有 android 9.0 *86 的 Nexus 5P 和 6P。

标签: androidreact-nativegoogle-play-services

解决方案


我今天遇到了同样的问题,最新版本的 com.google.android.gms.play-services-maps 是问题,降级到 16.0.0 修复了它。

Inside the app/build.gradle

dependencies {
   ...
 compile "com.google.android.gms:play-services-base:+" <---Remove this
 compile "com.google.android.gms:play-services-maps:+" <---Remove this
 compile "com.google.android.gms:play-services-base:16.0.1" <---Add this
 compile "com.google.android.gms:play-services-maps:16.0.0" <---Add this
}

希望能帮助到你。


推荐阅读