googlearchive / drive-android-quickstart

[MOVED] Quickstart application showing the Google Drive API for Android
https://github.com/gsuitedevs/android-samples
Apache License 2.0
238 stars 159 forks source link

Failed to create new contents. API failed to connect while resuming due to an unknown error. #17

Open qadirsuh opened 6 years ago

qadirsuh commented 6 years ago

Hi there,

I am getting follwing error after capturing the image.

11-09 12:27:45.537 6671-6671/genetechsolutions.intentsdemo I/drive-quickstart: Sign in request code
11-09 12:27:45.537 6671-6671/genetechsolutions.intentsdemo I/drive-quickstart: Signed in successfully.
11-09 12:27:52.751 6671-6677/genetechsolutions.intentsdemo W/art: Suspending all threads took: 8.588ms
11-09 12:27:55.041 6671-6671/genetechsolutions.intentsdemo I/drive-quickstart: capture image request code
11-09 12:27:55.041 6671-6671/genetechsolutions.intentsdemo I/drive-quickstart: Image captured successfully.
11-09 12:27:55.042 6671-6671/genetechsolutions.intentsdemo I/drive-quickstart: Creating new contents.
11-09 12:29:47.570 6671-6671/genetechsolutions.intentsdemo W/drive-quickstart: Failed to create new contents.
                                                                               com.google.android.gms.common.api.ApiException: 8: API failed to connect while resuming due to an unknown error.
                                                                                   at com.google.android.gms.common.internal.zzb.zzz(Unknown Source)
                                                                                   at com.google.android.gms.common.api.internal.zzg.zzu(Unknown Source)
                                                                                   at com.google.android.gms.common.api.internal.zze.zzt(Unknown Source)
                                                                                   at com.google.android.gms.common.api.internal.zzbr.zzx(Unknown Source)
                                                                                   at com.google.android.gms.common.api.internal.zzbr.zzahy(Unknown Source)
                                                                                   at com.google.android.gms.common.api.internal.zzbp.handleMessage(Unknown Source)
                                                                                   at android.os.Handler.dispatchMessage(Handler.java:98)
                                                                                   at android.os.Looper.loop(Looper.java:148)
                                                                                   at android.os.HandlerThread.run(HandlerThread.java:61)

I registered my package on google console. I have updated the google play services too.

I have also noticed that google play services is crashing after my app installed too. whats going on. any directions?

Ram8948 commented 6 years ago

Same issue in my code . have you got any solution?

qadirsuh commented 6 years ago

NO @Ram8948

gregoireternon commented 6 years ago

Exactly the same issue, and on other project android-demos, with a Sony Xperia XZ1 compact... did you get any answer, or did you find any workaround? This works fine on a Samsung Galaxy S4 mini sdk19

Bridouille commented 6 years ago

Hey, just ran into the same issue, the issue was that I hadn't enabled the Google Drive API in the developer console.

Somehow for you app to access the API you need to enable it. https://console.developers.google.com/apis/library/drive.googleapis.com