title: GameHelper Sign In Failed But Not GoogleAPIClient's Sign In
body: <p>I've been struggling to get GooglePlayServices hooked up using the GameHelper object. Upon opening my app, I get the "Unknown issue with Google Play services" popup and a signin error code of 8. I originally thought this was a problem with the way I set up my Google Play Services account, but after recreating it a few times and making sure everything is in check, I started thinking it was something else. </p>
  
  <p>So I tried setting up a separate GoogleApiClient to go along with the GameHelper object (even though it provides its own), and that client signs in just fine although the error message still pops up from the GameHelper object. So I took out the GameHelper object, but then the GoogleApiClient couldn't sign in again.</p>
  
  <p>I'd like to just use one or the other and not both, but it seems that if I use only one of these objects, it won't work. Is there something I'm missing in regards to the GameHelper or GoogleApiClient that I need to set up differently to get either of them to work independently?</p>
  
  <p>Here's the code:</p>
  
  <pre><code>public class MyHomeActivity extends FragmentActivity implements GoogleApiClient.ConnectionCallbacks, GoogleApiClient.OnConnectionFailedListener {
  
  private GameHelper gameHelper;
  private GoogleApiClient client;
  
  @Override
  public void onCreate(Bundle savedInstanceState) {
  
  private void setupGooglePlayServices() {
      client = new GoogleApiClient.Builder(this)
              .addApi(Games.API)
              .addScope(Games.SCOPE_GAMES)
              .addConnectionCallbacks(this)
              .addOnConnectionFailedListener(this)
              .build();
  
      GameHelper.GameHelperListener gameHelperListener = new GameHelper.GameHelperListener() {
          @Override
          public void onSignInFailed() {
              Log.i("Game Helper", "Sign in failed");
          }
  
          @Override
          public void onSignInSucceeded() {
              Log.i("Game Helper", "Sign in succeeded");
          }
      };
  
      gameHelper = new GameHelper(this, GameHelper.CLIENT_GAMES);
      //TODO Remove this for production
      gameHelper.enableDebugLog(true);
  
      gameHelper.setup(gameHelperListener);
  }
  
  @Override
  protected void onStart() {
      super.onStart();
      gameHelper.onStart(this);
      client.connect();
  }
  @Override
  protected void onStop() {
      super.onStop();
      gameHelper.onStop();
      client.disconnect();
  }
  
  @Override
  protected void onActivityResult(int requestCode, int resultCode, Intent data) {
      super.onActivityResult(requestCode, resultCode, data);
      gameHelper.onActivityResult(requestCode, resultCode, data);
  }
  
  @Override
  public void onConnected(Bundle bundle) {
      Log.i("Google API", "Connection Complete");
  }
  
  @Override
  public void onConnectionSuspended(int i) {
  
  }
  
  @Override
  public void onConnectionFailed(ConnectionResult connectionResult) {
      Log.i("Google API", "Connection Failed: " + connectionResult.toString());
  }
  </code></pre>
  
  <p>AndroidManifest.xml</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  &lt;manifest xmlns:android="http://schemas.android.com/apk/res/android"
        package="my.app.package"
        android:versionCode="2"
        android:versionName="1.0.1"&gt;
  
  &lt;uses-sdk
      android:minSdkVersion="14"
      android:targetSdkVersion="18" /&gt;
  
  &lt;application
      android:name=".MyApplication"
      android:allowBackup="true"
      android:icon="@drawable/ic_launcher"
      android:label="@string/app_name" &gt;
      &lt;activity android:name=".MyHomeActivity"
                android:screenOrientation="portrait"&gt;
          &lt;intent-filter&gt;
              &lt;action android:name="android.intent.action.MAIN" /&gt;
              &lt;category android:name="android.intent.category.LAUNCHER" /&gt;
          &lt;/intent-filter&gt;
      &lt;/activity&gt;
      &lt;activity android:name="com.google.android.gms.ads.AdActivity"
                android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"/&gt;
      &lt;meta-data android:name="com.google.android.gms.version"
                 android:value="@integer/google_play_services_version" /&gt;
      &lt;meta-data android:name="com.google.android.gms.games.APP_ID"
                 android:value="@string/google_play_id" /&gt;
      &lt;meta-data android:name="com.google.android.gms.appstate.APP_ID"
                 android:value="@string/google_play_id" /&gt;
  &lt;/application&gt;
  
  &lt;uses-permission android:name="android.permission.INTERNET" /&gt;
  &lt;uses-permission android:name="android.permission.GET_ACCOUNTS" /&gt;
  &lt;uses-permission android:name="android.permission.USE_CREDENTIALS" /&gt;
  
  
  &lt;/manifest&gt;
  </code></pre>
  
  <p>Logs</p>
  
  <pre><code>D/GameHelper﹕ GameHelper: Debug log enabled.
  D/GameHelper﹕ GameHelper: Setup: requested clients: 1
  D/GameHelper﹕ GameHelper: onStart
  D/GameHelper﹕ GameHelper: Connecting client.
  I/Google API﹕ Connection Complete  &lt;-- This is my log telling me the GoogleApiClient connected
  D/GameHelper﹕ GameHelper: onConnectionFailed
  D/GameHelper﹕ GameHelper: Connection failure:
  D/GameHelper﹕ GameHelper:    - code: INTERNAL_ERROR(8)
  D/GameHelper﹕ GameHelper:    - resolvable: false
  D/GameHelper﹕ GameHelper:    - details: ConnectionResult{statusCode=INTERNAL_ERROR,     resolution=null}
  D/GameHelper﹕ GameHelper: onConnectionFailed: WILL resolve because we have below the max# of attempts, 0 &lt; 3
  D/GameHelper﹕ GameHelper: onConnectionFailed: resolving problem...
  D/GameHelper﹕ GameHelper: resolveConnectionResult: trying to resolve result: ConnectionResult{statusCode=INTERNAL_ERROR, resolution=null}
  D/GameHelper﹕ GameHelper: resolveConnectionResult: result has no resolution. Giving up.
  W/GameHelper﹕ disconnect() called when client was already disconnected.
  D/GameHelper﹕ GameHelper: Notifying LISTENER of sign-in FAILURE (error)
  D/GameHelper﹕ GameHelper: onStop
  D/GameHelper﹕ GameHelper: Client already disconnected when we got onStop.
  </code></pre>