You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Ionic Native GooglePlus无报错静默登录失败问题求助

Ionic 3 GooglePlus Login Silently Fails (No Then/Catch Trigger, No Console Errors)

I’ve been following the official Ionic Google Plus integration guidelines to set up Google login for my app. I’ve created an Android OAuth client in Google Cloud Console, and verified the SHA-1 fingerprint is correct using the command:

keytool -list -printcert -jarfile <path to your apk>

Here’s my login code:

this.googlePlus.login({})
 .then(res => console.log(res))
 .catch(err => console.error(err));

The problem is that when I run this code, nothing happens—it never enters the then block, nor the catch block, and there are zero errors in the Chrome console.

Relevant Version Info

  • Ionic: 3.20.0
  • Cordova: 7.1.0
  • Ionic Native GooglePlus: 5.3.0
  • Android OS: 5.1.1
  • cordova-plugin-googleplus: 5.3.0

Other Ionic Native plugins (like Facebook) work perfectly fine. I’ve spent two days troubleshooting this with no luck.


Update 1

I tested modifying the cordova-plugin-googleplus native code to debug the issue. I altered the GooglePlus.execute method like this:

@Override
public boolean execute(String action, CordovaArgs args, CallbackContext callbackContext) throws JSONException {
 this.savedCallbackContext = callbackContext;
 savedCallbackContext.error(42);
 action = "abracadabra";
 ... // rest of the original code remains unchanged
}

After making this change, I can see the error code 42 in the Chrome console. This tells me there's a problem with how the plugin handles errors natively—it's not propagating errors back to the Ionic app properly.

I’m stuck and need technical guidance on how to fix this.

内容的提问来源于stack exchange,提问作者heroin

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.05.27 06:32:57