3

With help on this forum, I was finally able to run "bms-samples-hellotodo-advanced", which used MCA with Facebook authentication.

I'm still having no joy with "bms-samples-helloauthentication", which uses MCA with Google authentication.

I'm building and debugging with Android Studio, using Genymotion emulators. I'm following these instructions:

Everything builds with no warnings or errors. I'm able to start the app successfully.

But when I click "Ping Bluemix", the app displays: Bummer: something went wrong

  • I do not get a Google login dialog

  • I do not see any errors or warnings in Logcat

  • The debugger shows that I get past pingBluemix() > new Request(BMSClient.getInstance().getBluemixAppRoute() + "/protected", Request.GET).send(this, this);

  • But I do not ever hit onActivityResult(), so I never get a chance to call GoogleAuthenticationManager.getInstance().onActivityResultCalled()

  • cf logs helloAuthentication2 shows:

    2016-04-06T23:28:51.97-0700 [App/0] OUT [2016-04-07 06:28:51.971] [ERROR] [default] - Missing authorization

Q: How can I troubleshoot and resolve this problem?

Q: Is there any way I can troubleshoot MCA/Google authentication independent of running the Android app?

Like · Add comment

Community
  • 1
  • 1
paulsm4
  • 114,292
  • 17
  • 138
  • 190
  • 2
    Just to confirm, does your Genymotion emulator have Google Play Services installed? Additionally have you attempted using the native studio emulator to any success? Should also confirm your package name in your google OAuth client ID matches. If none of that helps it may be helpful for us to look at the server-side logs for which I'll need your public application ID for. Thanks – James Young IBM Apr 07 '16 at 19:53

1 Answers1

3

Many thanks to James Young above:

  1. No, my Genymotion emulators did not have Google Play Services installed. That was the problem.

  2. To install Google Play Services:

    a) Click on the browser

    b) Search for Google Play Services apk

    c) Install from Google Play (ideal) or

    d) Select a version on apkmirror.com and install manually

  3. Once Google Play Services were installed, "everything worked". When I clicked "Ping Bluemix", I got a dialog for a Google logon, and was successfully able to authenticate through Bluemix.

Thank you again, James!

paulsm4
  • 114,292
  • 17
  • 138
  • 190