Open pooyakn opened 7 years ago
Can you share an unfiltered log? There are important messages that are not in the Unity category.
Here's full log (without -s Unity) https://pastebin.com/0DbxbCQB
@claywilkinson did you find out anything?
@claywilkinson Is there anything wrong with my log?
Apologies for the slow response. I see this in the log:
E/Parcel ( 1377): Caused by: java.lang.ClassNotFoundException: Didn't find class "com.google.android.gms.auth.api.signin.internal.SignInConfiguration" on path: DexPathList[[directory "."],nativeLibraryDirectories=[/vendor/lib64, /system/lib64]]
Do you have play-services-auth-*.aar in your project?
@claywilkinson It's fine. I have these in my Plugin folder: "play-services-auth-11.0.4" and "play-services-auth-base-11.0.4". and if there is something wrong with authentication, how is it possible to sign in on other devices?
Hmm. Strange. Would you mind trying it with the Minimal sample (so we have the same code)? and share the full log? Also, which version of Android, Play Games App, and Play Game Services is installed on that device?
@claywilkinson Minimal sample log (it didn't work): https://pastebin.com/cvqBFUxX
Android: 5.1.1 Google Play Services: 11.3.02 Google Play Games: 5.2.25
Thanks for the info. I see this line in the log:
E/TokenFragment( 7709): Google SignIn Result is null?
Which comes from
https://github.com/playgameservices/play-games-plugin-for-unity/blob/master/source/SupportLib/PlayGamesPluginSupport/src/main/java/com/google/games/bridge/TokenFragment.java#L333
Unfortunately, it does not print out the resultCode. Do you think you can add the log statement and rebuild? I can try to add it and make an updated plugin, but I might not get to it today..
@claywilkinson Thanks for your quick response. How should I add that? or more specifically, I must say: "WHAT should I add, and to WHERE?"
:D on that like 333 add something like Log.e(TAG,"Failure getting result: " + resultCode);
Then recompile that java project and copy the jar file out. I'll try to share a gist with the updated code in about an hour or so...
you can download the updated jar from this gist: https://gist.github.com/claywilkinson/32cdb00e9a391833ab3e1eae52e1535f
It is based on 0.9.40 - but I don't think there are any differences that would make you have to update. B
Thanks! I was still struggling with android studio. :D
No problem - hopefully the added logging will point us in the right direction.
@claywilkinson Sorry for late response. Last night couldn't grab a xiaomi device. Here's new log: https://pastebin.com/STKhbqJt
No worries - I've passed it along to some colleagues who can help too - It is strange that the result is success but the result object is not present. I'll keep you posted.
@Starless-Sky - Apparently there are some xiaomi devices that do not have Google Play Services installed on them. This can cause this problem. The difference is when you request email, the code is using the GoogleSignIn API. Without the request for email, it uses the Games sign-in which does not access the user information.
For reference here is a related issue: https://github.com/googlesamples/google-services/issues/240
In a future release of Google SignIn API it will return a proper error code, so it is a little easier to diagnose.
@claywilkinson I have Google Play Services and Google Play Games installed and they are official versions, cause I am on golbal rom, not Chinese one. Also I have other games like 8 ball pool (mini clip) installed and it works fine. (8 ball pool also has the second screen that I have to give permission to access my data (other than my Play Games Profile), but that game is not made with Unity.
Another thing is when I add RequestEmail to the builder, It doesn't show the account selector UI (that green thing). I assume it tries to sign in silently, but fails when tries to show that second one to give permission to accees my email. However when I remove the RequestEmail thing, It signs in just fine, and the account selector UI does show up.
That's my assumption. I don't know if it's right, but if there's something I can test to help in the diagnosis process, please tell.
Thanks - can you share the model and version of the device so I can pass that along too?
You're welcome. Xiaomi redmi note 3 - Snapdragon version http://m.gsmarena.com/xiaomi_redmi_note_3-7863.php#global
on Android 5.1 MIUI 8
@Starless-Sky - I got hold of a redmi note 3 and it is working. I added some more error handling that should help to the jar in https://gist.github.com/claywilkinson/32cdb00e9a391833ab3e1eae52e1535f
If you would not mind downloading it again and trying it out.
My versions of software are a little different (for example play services is 11.0.55) and I am using play-services-auth-11.0.2, but I don't think that will make a difference.
Thanks!
Somewhat same issue here, but I tried removing .RequestEmail() still not working in Xiaomi redmi note 3 MIUI 9 (Android 6.01). I am using Google play games plugin 0.9.40 Works in Nokia 3 (Android 7), Xiaomi redmi (Android 4.4), LYF Flame 8 (Android 5.1)
Hi. I have a problem with getting user email on Xiaomi devices. When I add . RequestEmail to configuration builder, the account chooser ui doesn't show up on Xiaomi devices and user can't login. But on other devices it's okay, and when i remove that part, it's okay on xiaomies too. I'm using the latest .39a plugin, and have updated google play services in sdk manager.
here's log:
Thanks.