youtube / yt-direct-lite-android

The code is a reference implementation for an Android OS application that captures video, uploads it to YouTube, and submits the video to a YouTube Direct Lite instance.
276 stars 156 forks source link

Connection to Play Services failed #21

Open Redman1037 opened 7 years ago

Redman1037 commented 7 years ago

When I run this project it constantly shows toast "Connection to Play Services failed" . also i cannot select any google account . Using Samsung sduos 2 , Android 7.1.2

SophiaSonam commented 7 years ago

While creating credentials for OAuth 2.0 client IDs use this $ keytool -exportcert -alias androiddebugkey -keystore ~/.android/debug.keystore -list -v to get the SHA-1 fingerprint. I also had the same issue, but this worked for me.

softmarshmallow commented 7 years ago

didnt work for me...

solved this?

SophiaSonam commented 7 years ago

Yes

starapple2 commented 6 years ago

The "Connection to Play Services failed" can sometime be related to permission not being granted to "android.permission.GET_ACCOUNTS" in versions of Android greater than Marshmallow. That is how I solved the problem with Android 7.Then after granting permission I had to set a precondition for launching on versions pre Marshmallow:

if (Build.VERSION.SDK_INT >= 23) {
                // Verify that all required contact permissions have been granted.
}
alfredmack commented 6 years ago

@Redman1037 Please check this updated fork https://github.com/alfredmack/YouTube-Video-Uploader