statusCode=SIGN_IN_REQUIRED, resolution=null 只有開發者 ID 可以登錄 else 錯誤 (statusCode=SIGN_IN_REQUIRED, resolution=null Only developer Id can Login else error)


問題描述

statusCode=SIGN_IN_REQUIRED, resolution=null 只有開發者 ID 可以登錄 else 錯誤 (statusCode=SIGN_IN_REQUIRED, resolution=null Only developer Id can Login else error)

GoogleSignInOptions.DEFAULT_GAMES_SIGN_IN 只允許我的開發者 ID 登錄,否則,如果我嘗試使用其他 ID,則會引發錯誤

statusCode=SIGN_IN_REQUIRED,分辨率=null

如何使用其他 id 登錄?

public void signin()
{  
 mGoogleSignInClient= GoogleSignIn.getClient(this,  GoogleSignInOptions.DEFAULT_GAMES_SIGN_IN);


     Intent intent= mGoogleSignInClient.getSignInIntent();

       startActivityForResult(intent, REQ_CODE);
  }


     @Override
          protected void onActivityResult(int requestCode, int resultCode, @Nullable Intent data) {
    super.onActivityResult(requestCode, resultCode, data);
    if (requestCode==REQ_CODE)
    {

        GoogleSignInResult result= Auth.GoogleSignInApi.getSignInResultFromIntent(data);
        handleResult(result);
    }

Error is LoginResult: Status{statusCode=SIGN_IN_REQUIRED, resolution=null}


參考解法

方法 1:

You need to add Tester account in your Google Console for your project See the following link for more. https://developers.google.com/games/services/console/testpub Thanks

(by Umer KhaldiUmer Ik)

參考文件

  1. statusCode=SIGN_IN_REQUIRED, resolution=null Only developer Id can Login else error (CC BY‑SA 2.5/3.0/4.0)

#google-play-services #Android #google-signin






相關問題

無法從 Android SDK 管理器安裝/下載 SDK (Unable to install/download SDK from Android SDK manager)

google-play-services_lib.jar bị thiếu trong thư mục lib SDK google_play_services (google-play-services_lib.jar missing from SDK google_play_services lib folder)

谷歌播放服務認證(oauth 2.0) (Google play service authentication (oauth 2.0))

在帶有 Android 的 Xamarin Studio 上使用 AdMob,Google Play 服務不存在 (Use AdMob on Xamarin Studio with Android, Google Play Services don't exist)

谷歌登錄使用新的 GoogleSignInOptions 獲取訪問令牌 (Google login get access token with new GoogleSignInOptions)

在組織內分發 Android 應用 (Distribute Android apps within organization)

如何提供啟用 GPS 的選項 (How to give option for enable GPS)

玩遊戲服務,我們能知道我們什麼時候通過另一個hiscore嗎? (Play Game Services, can we know when we pass another hiscore?)

Android 使用 Google 的位置服務對話框 (Android Use Google's location service dialog)

statusCode=SIGN_IN_REQUIRED, resolution=null 只有開發者 ID 可以登錄 else 錯誤 (statusCode=SIGN_IN_REQUIRED, resolution=null Only developer Id can Login else error)

項目中同時擁有 GMS 和 HMS (Have both GMS and HMS in the project)

谷歌cast MediaNotificationService 中的大量RemoteServiceExceptions (Large number of RemoteServiceExceptions in Google's cast MediaNotificationService)







留言討論