On Sat, Nov 13, 2010 at 12:16, ocelma <oce
...@gmail.com> wrote:
> BTW, in the issue #176 I attached some code to test it. and I paste
> it here as well.
> So, can anyone please try this out and let me know whether it works
> fine for you, or not...
> Thanks!
> ====
> import twitter
> USER = 'YOUR_USERNAME'
> PASSWD = '****'
> CONSUMER_KEY = '****' # generated via get_access_token.py
> CONSUMER_SECRET = '****' # generated via get_access_token.py
> api = twitter.Api(consumer_key=USER, consumer_secret=PASSWD,
> access_token_key=CONSUMER_KEY, access_token_secret=CONSUMER_SECRET,
> debugHTTP=True)
The values for the parameters of consumer_key and consumer_secret are
not your web-based twitter userid and password, but rather the values
you are assigned by twitter when you created the Application (and also
what you had to give inside of get_access_token.py.)
I would change your code to read:
import twitter
CONSUMER_KEY = 'value_of_your_apps_consumer_key'
CONSUMER_SECRET = 'value_of_your_apps_consumer_secret'
ACCESS_KEY = '****' # generated via get_access_token.py
ACCESS_SECRET = '****' # generated via get_access_token.py
api = twitter.Api(consumer_key=CONSUMER_KEY, consumer_secret=CONSUMER_SECRET,
access_token_key=ACCESS_KEY, access_token_secret=ACCESS_SECRET,
debugHTTP=True)
> print api.GetUserTimeline()[0] #This works fine...
> message ='Just testing OAuth...please work! ;-
> ('
> status = api.PostUpdate(message)
> #Error: twitter.TwitterError: Incorrect signature
> ====
> On Nov 13, 5:32 pm, ocelma <oce...@gmail.com> wrote:
>> On Nov 12, 8:31 pm, python-twit...@googlecode.com wrote:
>> > Comment #1 on issue 176 by adam.aviv: PostUpdate (still) returns
>> > IncorrectSignature (continuation of issue #157)http://code.google.com/p/python-twitter/issues/detail?id=176
>> > Have you tied regenerating your access tokens?
>> I just did that, using the get_access_token.py script:
>> ====
>> Requesting temp token from Twitter
>> Please visit this Twitter page and retrieve the pincode to be used
>> in the next step to obtaining an Authentication Token:
>> https://api.twitter.com/oauth/authorize?oauth_token=B9zeRILjowPA5S7bC...
>> Pincode? **********
>> Generating and signing request for an access token
>> Your Twitter Access Token key: ****
>> Access Token secret: ****
>> ====
>> > Also, check that your
>> > application is still listed.
>> Yes, it is.
>> These are the settings:
>> ====
>> App type: client
>> Access: read & write
>> Use twitter for login: [no]
>> ====
>> The app (http://twitter.com/groovify) is just python script that
>> scans the spotify/last.fm/grooveshark links in the tweets, and replies
>> that user with a link that has playlist generated based on that (seed)
>> song.
>> More info here:http://denoiserthebetter.posterous.com/groovify-your-music-tweets
>> And here's an example:http://ella.bmat.me/groovify?id=515c13bd-3eea-4f4f-a6e6-9055d3ca7654&...
>> That's it!
>> Any help would be very much appreciated.
>> Thanks!
>> Oscar
>> > I've also found that if your clock skew is too far off, this will mess up
>> > the nonce, and thus the signature.
> --
> You received this message because you are subscribed to the Google Groups "python-twitter" group.
> To post to this group, send email to python-twitter@googlegroups.com.
> To unsubscribe from this group, send email to python-twitter+unsubscribe@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/python-twitter?hl=en.
--
Bear
b...@xmpp.org (email)
bea...@gmail.com (xmpp, email)
b...@code-bear.com (xmpp, email)
http://code-bear.com/bearlog (weblog)
PGP Fingerprint = 9996 719F 973D B11B E111 D770 9331 E822 40B3 CD29