I am getting error of google Plus Login Failed error code 17 while using the release apk. In debug apk it is working. not able to figure it out the proper error and solution.Even error message is null.
@Override
public void onConnectionFailed(ConnectionResult result) {
Log.e(TAG, "Google plus login failed : onConnectionFailed");
if (!mIntentInProgress && result.hasResolution()) {
try {
mIntentInProgress = true;
mActivity.startIntentSenderForResult(result.getResolution()
.getIntentSender(), AUTH_CODE_REQUEST_CODE, null, 0, 0, 0);
} catch (SendIntentException e) {
mIntentInProgress = false;
mGoogleApiClient.connect();
}
} else {
if (mGoogleLoginListener != null) // it goes here
mGoogleLoginListener.googlePlusLoginFailed(result.getErrorCode());
}
}
I finally found answer!
According to google document about Debug & release we have to generate both debug and release SHA-1 fingerprint using the keytool. I also found link.
Steps followed by me:
For debug SHA-1:
keytool -list -v -keystore -alias For Debug, replace with your debug.keystore path, for Example :
keytool -list -v -keystore C:\Users\Desktop.android\debug.keystore -alias androiddebugkey
Password: android
For Release SHA-1, replace with your keystore path and alias password, for Example :
keytool -list -v -keystore C:\ProjectTest\keystore\my-release-key.jks -alias alias_name
Password: Your alias password.