Comments (6)
Can you provide an http log?
https://code.google.com/p/google-api-objectivec-client/wiki/Introduction#Logging
_HTTP_Server_Traffic
Original comment by [email protected]
on 4 Dec 2013 at 6:21
from gtm-oauth2.
Sure, here's the log:
youtube.videos.insert
2013-12-04 09:04:10 +0000
Request: POST
https://www.googleapis.com/upload/rpc?uploadType=resumable&prettyPrint=false
Request headers:
Accept: application/json-rpc
Authorization: Bearer _snip_
Cache-Control: no-cache
Content-Type: application/json-rpc; charset=utf-8
User-Agent: jp.nagisa-inc.FOOBAR/1.0 google-api-objc-client/2.0 iPhone/7.0.2 (gzip)
X-Upload-Content-Length: 9680229
X-Upload-Content-Type: video/x-m4v
Request body: (383 bytes)
{
"method" : "youtube.videos.insert",
"id" : "gtl_1",
"jsonrpc" : "2.0",
"params" : {
"part" : "snippet,status",
"resource" : {
"status" : {
"privacyStatus" : "public"
},
"snippet" : {
"description" : "FOOBAR",
"title" : "FOOBAR",
"tags" : [
"FOOBAR"
]
}
}
},
"apiVersion" : "v3"
}
Response: status 200
Response headers:
Alternate-Protocol: 443:quic
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Content-Length: 209
Content-Type: application/json
Date: Wed, 04 Dec 2013 09:04:11 GMT
Expires: Fri, 01 Jan 1990 00:00:00 GMT
Pragma: no-cache
Server: HTTP Upload Server Built on Nov 15 2013 16:02:54 (1384560174)
Response body: (209 bytes)
{
"id" : "gtl_1",
"error" : {
"message" : "Unauthorized",
"code" : -32602,
"data" : [
{
"domain" : "youtube.header",
"reason" : "youtubeSignupRequired",
"locationType" : "header",
"location" : "Authorization",
"message" : "Unauthorized"
}
]
}
}
-----------------------------------------------------------
Original comment by [email protected]
on 5 Dec 2013 at 12:59
from gtm-oauth2.
I commented out the two assertions so it returns an error instead of crash.
(just as it would in non-debug build if I understand correctly)
Original comment by [email protected]
on 5 Dec 2013 at 1:01
from gtm-oauth2.
The fetcher was written expecting errors as http status codes, but the YouTube
API is now retuning them as JSON. I'll modify the library to not assert there,
effectively similar to what you've done.
Incidentally, this issue tracker is intended for the OAuth 2 library, not for
the GTL library.
Original comment by [email protected]
on 5 Dec 2013 at 1:37
- Changed state: Accepted
from gtm-oauth2.
much appreciated.
Original comment by [email protected]
on 5 Dec 2013 at 1:44
from gtm-oauth2.
This should be resolved in the top-of-trunk library. Please update your library
sources.
https://code.google.com/p/gtm-http-fetcher/source/detail?r=134
Thank you for reporting the issue.
Original comment by [email protected]
on 6 Dec 2013 at 11:33
- Changed state: Fixed
from gtm-oauth2.
Related Issues (20)
- Patch for /trunk/Source/GTMOAuth2Authentication.h HOT 1
- GTMOAuth2Authentication expiresIn can return wrong type HOT 1
- ARC compatibility HOT 3
- GTMOAuth2ViewControllerTouch does not support endpoints using HTTP basic authentication
- Unable to customize navigationBar/navigationItem properties if GTMOAuth2ViewController is the rootViewController
- Authentication breaks when redirectURI is of the form scheme:/path
- Invalid convertion from BOOL to (NSMutableDictionary*) HOT 1
- JSON format issue for POJO objects as @ApiMethod parameters
- Extension Grants
- GTMOAuth2ViewControllerTouch doesn't correctly handle dismissal with a pop gesture
- GTMOAuth2Authentication.refreshScope is either useless or broken HOT 1
- GTMOAuth2ViewControllerTouch needs refactoring HOT 1
- Application problem (Question by non-programmer, sorry) HOT 2
- iOS 7 user interface
- auth.userEmail getting wrong email address HOT 2
- iOS setCookie HOT 3
- Hi, i got an error while using vpn HOT 1
- Support text/javascript as valid content-type for JSON responses HOT 1
- Patch for /trunk/Source/GTMOAuth2Authentication.h HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gtm-oauth2.