当我尝试使用Android应用上的G +为尚未在设备Google帐户中登录的新用户登录时,我得到INTERNAL_ERROR with status 8
并且屏蔽将一直保持到用户点击屏蔽为止。当我们再次为同一个用户重试时,我获得了成功的登录响应。
Google登录选项代码:
GoogleSignInOptions.Builder gso = new GoogleSignInOptions.Builder(GoogleSignInOptions.DEFAULT_SIGN_IN);
gso.requestEmail().requestProfile();
String webClientId = clientOptions.optString(ARGUMENT_WEB_CLIENT_ID, null);
gso.requestIdToken(webClientId);
gso.requestServerAuthCode(webClientId, false);
GoogleApiClient.Builder builder = new GoogleApiClient.Builder(webView.getContext())
.addOnConnectionFailedListener(this)
.addApi(Auth.GOOGLE_SIGN_IN_API, gso.build());
this.mGoogleApiClient = builder.build();
注意:适用于已登录设备Google帐户的用户。