I'm really sorry for the flood, but I just found a way to fix the 411,
but now I'm getting "net.oauth.OAuthProblemException: HTTP/1.0 417
Expectation failed"

It seems I'm not the only one (http://groups.google.com/group/
opensocial-orkut/browse_thread/thread/806040c98b7c3dbc/
296a7cb908791072), but I found no solution to 417..

On Aug 11, 4:18 pm, Paulo Cesar <[email protected]> wrote:
> Ok, now that I'm debugging it, I found the real problem... I'm getting
> Error 411:
>
> "HTTP response => HTTP/1.0 411 Length Required
>
> Server: squid/2.7.STABLE3
>
> Date: Wed, 11 Aug 2010 19:12:59 GMT
>
> Content-Type: text/html
>
> Content-Length: 1684
>
> Expires: Wed, 11 Aug 2010 19:12:59 GMT
>
> X-Squid-Error: ERR_INVALID_REQ 0
>
> X-Cache: MISS from fw.ctba.cesar.org.br
>
> X-Cache-Lookup: NONE from fw.ctba.cesar.org.br:3128
>
> Via: 1.0 fw.ctba.cesar.org.br:3128 (squid/2.7.STABLE3)
>
> Connection: close
>
> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" 
> "http://www.w3.org/TR/html4/loose.dtd";>
> <HTML><HEAD><META HTTP-EQUIV="Content-Type" CONTENT="text/html;
> charset=iso-8859-1">
> <TITLE>ERROR: The requested URL could not be retrieved</TITLE>
> <STYLE type="text/css"><!--BODY{background-color:#ffffff;font-
> family:verdana,sans-serif}PRE{font-family:sans-serif}--></STYLE>
> </HEAD><BODY>
> <H1>ERROR</H1>
> <H2>The requested URL could not be retrieved</H2>
> <HR noshade size="1px">
> <P>
> While trying to process the request:
> <PRE>
> POST /social/rpc?
> oauth_token=**********&amp;oauth_consumer_key=fabricialeme.com&amp;oauth_signature_method=HMAC-
> SHA1&amp;oauth_timestamp=1281553979&amp;oauth_nonce=4026785411852&amp;oauth_version=1.0&amp;oauth_signature=*****************
> HTTP/1.1
> Content-Type: application/json
>
> X-Orkut-Client-Lib: 1.1
>
> Transfer-Encoding: chunked
>
> Host:www.orkut.com
>
> Connection: Keep-Alive
>
> User-Agent: Apache-HttpClient/4.0-beta2 (java 1.5)
>
> Expect: 100 ..."
>
> I saw in another thread that I need to "put the Content-Length header
> in your request", but I'm just not sure how to do this on this java
> client.. Anyway, I'll continue trying to make it work, but if anyone
> knows a solution, please post it here :)
>
> Bye
>
> On Aug 11, 2:37 pm, Paulo Cesar <[email protected]> wrote:
>
> > Yeah, the first thing I thought was to debug the samples to understand
> > how that JSONs are arriving for me.. The problem is I have very little
> > experience on Java development, and I'm having a bad time figuring out
> > how to run that code inside an IDE so I can debug it...
>
> > Well, I think I'll loose this afternoon learning that then, and trying
> > to code a workaround for the problem. If I manage to debug it, I'll
> > post here more details about the problem.
>
> > Thanks, bye
>
> > On Aug 11, 2:26 pm, Robson Dantas <[email protected]> wrote:
>
> > > Hi Paulo,
>
> > > Got one issue when developing my lib, with an invalid json response from
> > > orkut too.
>
> > >http://code.google.com/p/orkut-os-client-php/source/browse/trunk/lib/...
>
> > > <http://code.google.com/p/orkut-os-client-php/source/browse/trunk/lib/...>Go
> > > to the line 298, and see what i've done. Probably this is the same 
> > > problem.
>
> > > Can you debug the code to check Orkut response?
>
> > > -Robson Dantas
>
> > > 2010/8/11 Paulo Cesar <[email protected]>
>
> > > > Ah no, this oauth file is from before running "ant run-sample". When I
> > > > run it, it opens a browser window, I click on grant access to
> > > > fabricialeme.com and then the error message appears on terminal.
>
> > > > Here is the oauth file after running the sample:
>
> > > > #writing access Token
> > > > #Wed Aug 11 10:32:28 BRT 2010
> > > > accessUrl=https\://www.google.com/accounts/OAuthGetAccessToken
> > > > consumerSecret=RLGge***********************
> > > > serverUrl=http\://www.orkut.com/social/rpc
> > > > token_secret=DNzeRk367L**********
> > > > requestUrl=https\://www.google.com/accounts/OAuthGetRequestToken
> > > > accessToken=1/UX72lWGE-3SJyq4**************************************
> > > > saveAccessToken=true
> > > > consumerKey=fabricialeme.com
> > > > authorizationUrl=https\://www.google.com/accounts/OAuthAuthorizeToken
> > > > scope=http\://orkut.gmodules.com/social
>
> > > > By the way, thanks for the help!
>
> > > > On Aug 11, 10:26 am, "Prashant (Google)" <[email protected]> wrote:
> > > > > Hi Paulo,
>
> > > > > Replying publicly to your private mail, so we can discuss this with
> > > > > everyone...
>
> > > > > So is this happening when you're trying to authenticate for the first
> > > > > time, when you haven't yet got back the accessToken (because I don't
> > > > > see it set in the oauth properties)? Are you running the sample
> > > > > directly from the command line (ant run-sample?) or using an IDE?
>
> > > > > And no, we won't block your consumer key without reason.
>
> > > > > ~Prashant
>
> > > > > On Aug 11, 6:19 pm, Paulo Cesar <[email protected]> wrote:
>
> > > > > > I don't think it's an authentication problem. Please see this part 
> > > > > > of
> > > > > > the error:
>
> > > > > > Caused by: org.json.me.JSONException: A JSONArray text must start 
> > > > > > with
> > > > > > '[' at character 0 of
> > > > > >      [java]     at
> > > > org.json.me.JSONTokener.syntaxError(JSONTokener.java:
> > > > > > 448)
> > > > > >      [java]     at org.json.me.JSONArray.<init>(JSONArray.java:106)
> > > > > >      [java]     at org.json.me.JSONArray.<init>(JSONArray.java:145)
> > > > > >      [java]     ... 30 more
> > > > > >      [java] --- Nested Exception ---
>
> > > > > > It seems that it can authenticate successfully, but the JSON 
> > > > > > response
> > > > > > is empty. Is my application being blocked?
>
> > > > > > Here's my oauth file:
>
> > > > > > # enter the consumer key and secret here
> > > > > > consumerKey=**myconsumerkey**
> > > > > > consumerSecret=**mysecret**
> > > > > > accessUrl=https\://www.google.com/accounts/OAuthGetAccessToken
> > > > > > authorizationUrl=https\://www.google.com/accounts/OAuthAuthorizeToken
> > > > > > requestUrl=https\://www.google.com/accounts/OAuthGetRequestToken
> > > > > > saveAccessToken=true
> > > > > > scope=http\://orkut.gmodules.com/social
> > > > > > serverUrl=http\://www.orkut.com/social/rpc
>
> > > > > > Is anything wrong with it?
>
> > > > > > On Aug 10, 6:41 pm, Robson Dantas <[email protected]> wrote:
>
> > > > > > > Paulo,
>
> > > > > > > Open a bug on the library website. I'm getting several 
> > > > > > > authentication
> > > > > > > problems, and it was reported before.
>
> > > > > > > Basically, there are two different problems:
>
> > > > > > > 1- When you try to authenticate and orkut returns an invalid base
> > > > string
> > > > > > > authentication. It happens on my lib, googleoauth playground and 
> > > > > > > also
> > > > on
> > > > > > > java lib;
>
> > > > > > > 2- When "authenticated", orkut refuses the access token, 
> > > > > > > returning an
> > > > > > > invalid token;
>
> > > > > > > When was testing java lib, these errors were responsible for 
> > > > > > > raising
> > > > > > > exceptions.
>
> > > > > > > Regards
>
> > > > > > > Robson Dantas
>
> > > > > > > 2010/8/10 Paulo Cesar <[email protected]>
>
> > > > > > > > Anybody knows when the problem described bellow will be fixed?
>
> > > > > > > > "When i ran the project, after specifying my Consumer key and
> > > > Secret,
> > > > > > > > the Request was made normally, however, the response had 
> > > > > > > > problems.
> > > > The
> > > > > > > > program ended with an exception as follows, (by the way I did do
> > > > the
> > > > > > > > authentication, i.e, logged in to my Orkut account to grant 
> > > > > > > > access)
>
> > > > > > > > Request:[{"params":{"groupId":"@self","userId":"@me"},"id":"0-
> > > > > > > > p.g","method":"people.get"},{"params":
> > > > > > > > {"groupId":"@friends","userId":"@me","count":20,"startIndex":
> > > > > > > > 0},"id":"1-frnds.g","method":"people.get"}]
> > > > > > > > Exception in thread "main" java.lang.RuntimeException: 
> > > > > > > > Unexpected
> > > > > > > > exception while setting response
> > > > > > > >        at
>
> > > > com.google.orkut.client.api.BatchTransaction.setResponse(BatchTransaction.j
> > > > ava:
> > > > > > > > 169)
> > > > > > > >        at
> > > > com.google.orkut.client.sample.Transport.run(Transport.java:104)
> > > > > > > >        at
> > > > com.google.orkut.client.sample.SampleApp.run(SampleApp.java:57)
> > > > > > > >        at
> > > > com.google.orkut.client.sample.SampleApp.main(SampleApp.java:43)
> > > > > > > > Caused by: org.json.me.JSONException: A JSONArray text must 
> > > > > > > > start
> > > > with
> > > > > > > > '[' at character 0 of
> > > > > > > >        at 
> > > > > > > > org.json.me.JSONTokener.syntaxError(JSONTokener.java:448)
> > > > > > > >        at org.json.me.JSONArray.<init>(JSONArray.java:106)
> > > > > > > >        at org.json.me.JSONArray.<init>(JSONArray.java:145)
> > > > > > > >        at
>
> > > > com.google.orkut.client.api.BatchTransaction.setResponse(BatchTransaction.j
> > > > ava:
> > > > > > > > 159)
> > > > > > > >        ... 3 more"
>
> > > > > > > > I can't run even the simplest samples, can anyone help me on 
> > > > > > > > this?
>
> > > > > > > > On Jun 29, 7:00 am, chaitu <[email protected]> wrote:
> > > > > > > > > Thanks Prashanth for the reply.
>
> > > > > > > > > We hope the activities reply functionality is implemented in 
> > > > > > > > > near
> > > > > > > > > future.
>
> > > > > > > > > As i explored the present API i found that few activity types
> > > > > > > > > implementation is missing like
> > > > > > > > > COMMUNITY_JOIN and others. they are just been marked as
> > > > > > > > > GenericActivity without
> > > > > > > > > returning even a text for that except ownerprofile.
> > > > > > > > > Is it true or am i missing anything here for specific activity
> > > > types.
>
> > > > > > > > > Thanks,
> > > > > > > > > Chaitu
>
> > > > > > > > > On Jun 16, 4:03 pm, "Prashant (Google)" <[email protected]> 
> > > > > > > > > wrote:
>
> > > > > > > > > > Hi,
>
> > > > > > > > > > This is definitely the right place to talk about it!
>
> > > > > > > > > > But no, can't comment on activities at the moment.
>
> > > > > > > > > > ~Prashant
>
> > > > > > > > > > On Jun 10, 4:26 pm, chaitu <[email protected]> wrote:
>
> > > > > > > > > > > Hi Prashant,
>
> > > > > > > > > > > Thanks for the library which is helping us in good way.
> > > > > > > > > > > It may be not the correct place but i just need to know 
> > > > > > > > > > > does
> > > > the
> > > > > > > > > > > library code include
> > > > > > > > > > > commenting for an activity.
>
> ...
>
> read more »

-- 
You received this message because you are subscribed to the Google Groups 
"orkut Developer Forum" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/opensocial-orkut?hl=en.

Reply via email to