应用程序不能正确地配置为使用谷歌游戏服务 [英] App not correctly configured to use Google Play services

查看:833
本文介绍了应用程序不能正确地配置为使用谷歌游戏服务的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经被困在这几个小时,似乎没有什么是工作。

I've been stuck on this for hours and nothing seems to be working.

我有一个简单的游戏,我想与谷歌Play业务整合。我感兴趣的是加入了排行榜和一些成果。

I have a simple game which I'm trying to integrate with Google Play services. I'm interested in adding a leaderboard and a few achievements.

这是我做了什么:

  1. MainActivity延伸BaseGameActivity,我已经导入了BaseGameUtils项目和谷歌播放-services_lib项目。我已经添加了他们两个作为游戏的库项目。

  1. MainActivity extends BaseGameActivity, and I've imported the BaseGameUtils project and the google-play-services_lib projects. I've added them both as Library projects of the game.

我在谷歌开发者控制台为我的产品,我的调试键创建了两个客户端ID。

I've created two client IDs in Google Developers console for both my product and my debug keys.

我说我的电子邮件如谷歌Play开发者控制台测试仪,在游戏服务部分,并为这个应用程序。

I added my email as a tester in the Google Play Developer console, in the Game Services section and for this app.

当我运行的应用程序,我可以看到谷歌播放服务对话框,我可以选择一个帐户,我可以看到的权限对话框。然而,当我点击确定我得到以下信息:

When I run the app, I can see the Google Play services dialog, and I can select an account and I can see the permissions dialog. However when I click Ok I get the following message:

The application is incorrectly configured. Check that the package name and signing certificate match the client ID created in Developer Console. Also, if the application is not yet published, check that the account you are trying to sign in with is listed as a tester account. See logs for more information.

日志说以下内容:

03-14 16:45:08.023: W/GameHelper(3839): **** APP NOT CORRECTLY CONFIGURED TO USE GOOGLE PLAY GAME SERVICES
03-14 16:45:08.023: W/GameHelper(3839): **** This is usually caused by one of these reasons:
03-14 16:45:08.023: W/GameHelper(3839): **** (1) Your package name and certificate fingerprint do not match
03-14 16:45:08.023: W/GameHelper(3839): ****     the client ID you registered in Developer Console.
03-14 16:45:08.023: W/GameHelper(3839): **** (2) Your App ID was incorrectly entered.
03-14 16:45:08.023: W/GameHelper(3839): **** (3) Your game settings have not been published and you are 
03-14 16:45:08.023: W/GameHelper(3839): ****     trying to log in with an account that is not listed as
03-14 16:45:08.023: W/GameHelper(3839): ****     a test account.
03-14 16:45:08.023: W/GameHelper(3839): ****
03-14 16:45:08.023: W/GameHelper(3839): **** To help you debug, here is the information about this app
03-14 16:45:08.023: W/GameHelper(3839): **** Package name         : com.blabla.myapp
03-14 16:45:08.031: W/GameHelper(3839): **** Cert SHA1 fingerprint: A9:5C:17:57:0D:74:1A:11:FF:8C:03:B9:7C:8D:49:12:9F:D6:2A:2C
03-14 16:45:08.031: W/GameHelper(3839): **** App ID from          : 71440642016
03-14 16:45:08.031: W/GameHelper(3839): ****
03-14 16:45:08.031: W/GameHelper(3839): **** Check that the above information matches your setup in 
03-14 16:45:08.031: W/GameHelper(3839): **** Developer Console. Also, check that you're logging in with the
03-14 16:45:08.031: W/GameHelper(3839): **** right account (it should be listed in the Testers section if
03-14 16:45:08.031: W/GameHelper(3839): **** your project is not yet published).
03-14 16:45:08.031: W/GameHelper(3839): ****
03-14 16:45:08.031: W/GameHelper(3839): **** For more information, refer to the troubleshooting guide:
03-14 16:45:08.031: W/GameHelper(3839): ****   http://developers.google.com/games/services/android/troubleshooting

所有的数据记录中表现出是完全一样的应用程序。我甚至tryed只是复制/粘贴日志中的数据来创建一个新的客户端ID,我也得到了同样的错误。

ALL the data showed in the log is exactly the same as in the app. I've even tryed just copy/pasting the data in the log to create a new client ID and I get the same error.

我还重读在 http://developers.google.com的故障排除指南/游戏/服务/安卓/故障排除,一切似乎确定。

I've also reread the troubleshooting guide at http://developers.google.com/games/services/android/troubleshooting and everything seems ok.

我收到日志几次也可采用以下错误消息。我不知道是否有什么关系。我GOOGLE了它,并不能修复或者:

I'm getting the following error message in the logs a few times also. I'm not sure if it has anything to do. I've Googled it and can't fix it either:

03-14 16:45:01.960: E/GooglePlayServicesUtil(3839): The Google Play services resources were not found. Check your project configuration to ensure that the resources are included.

在更新测试用户需要几个小时?它已经至少3个或4个,因为我说我自己。

Can updating the test users take several hours? It's been at least 3 or 4 since I added myself.

任何想法?我完全没了主意,在这一点上。

Any ideas? I'm totally out of ideas at this point.

唯一相关的code是在我的onCreate()方法:

The only related code is in my onCreate() method:

    // Google Play Services
    GoogleApiClient mGoogleApiClient = new GoogleApiClient.Builder(this)
    .addApi(Games.API)
    .addScope(Games.SCOPE_GAMES)
    .build();


    mGoogleApiClient.connect();

我也试着运行示例应用程序(A型号码的挑战),我得到同样的错误设置的一切行动后,即使值也类似于谷歌开发控制台报告的值。

I've also tried running the sample app (Type-a-number challenge) and after setting everything up I'm getting the same error, even though the values are also similar to the reported values in the Google Dev Console.

谢谢!

推荐答案

我有同样的问题。我遵循这个指南

I have the same problem. I followed this guide

https://developers.google.com/games/services/android/troubleshooting

尽管修订本指南中的每个主题(如果你有在配置一些错误是necesary),问题依然存在。

Despite revising every topic in this guide (which is necesary if you have some mistakes in configuration), the problem persisted.

要解决这个问题,我清楚的链接的应用程序,我再一次创造了它。但是,而不是通过谷歌开发者控制台创建它,我创造了它,通过谷歌播放控制台。因此,对于每个SH1 code,创建新的链接的应用程序,然后问题就解决了​​。

To solve it, i clear linked application and I created it again. But instead of creating it through Google Developer Console, I created it through Google Play Console. So for each SH1 code, I create new linked application, and then problem solved

这篇关于应用程序不能正确地配置为使用谷歌游戏服务的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆