AuthorizationException Network Error FileNotFound

219 views
Skip to first unread message

Ricky de Klerck

unread,
Dec 19, 2016, 5:32:14 AM12/19/16
to Google Cloud Print Developers
Hi,

I'm trying to use the google cloud print api to send a document to a printer from my Android application. It all works fine when I use the account used in the example: https://github.com/googlecodelabs/appauth-android-codelab .

I created an account for myself in the google api console and used the same callback as in the example, but than I get this error:

                                                          AuthorizationException: {"type":0,"code":3,"errorDescription":"Network error"}
                                                              at net.openid.appauth.AuthorizationService$TokenRequestTask.doInBackground(AuthorizationService.java:244)
                                                              at net.openid.appauth.AuthorizationService$TokenRequestTask.doInBackground(AuthorizationService.java:206)
                                                              at android.os.AsyncTask$2.call(AsyncTask.java:292)
                                                              at java.util.concurrent.FutureTask.run(FutureTask.java:237)
                                                              at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:231)
                                                              at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112)
                                                              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587)
                                                              at java.lang.Thread.run(Thread.java:818)
                                                           Caused by: java.io.FileNotFoundException: https://www.googleapis.com/oauth2/v4/token
                                                              at com.android.okhttp.internal.http.HttpURLConnectionImpl.getInputStream(HttpURLConnectionImpl.java:206)
                                                              at com.android.okhttp.internal.http.DelegatingHttpsURLConnection.getInputStream(DelegatingHttpsURLConnection.java:210)
                                                              at com.android.okhttp.internal.http.HttpsURLConnectionImpl.getInputStream(HttpsURLConnectionImpl.java:25)
                                                              at net.openid.appauth.AuthorizationService$TokenRequestTask.doInBackground(AuthorizationService.java:239)
                                                              at net.openid.appauth.AuthorizationService$TokenRequestTask.doInBackground(AuthorizationService.java:206) 
                                                              at android.os.AsyncTask$2.call(AsyncTask.java:292) 
                                                              at java.util.concurrent.FutureTask.run(FutureTask.java:237) 
                                                              at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:231) 
                                                              at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112) 
                                                              at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587) 
                                                              at java.lang.Thread.run(Thread.java:818) 

Is there something I didn't enable for it to work? The same code works with the other account.

Ricky de Klerck

unread,
Dec 29, 2016, 3:43:42 AM12/29/16
to Google Cloud Print Developers
No ideas anyone?
Reply all
Reply to author
Forward
0 new messages