views:

212

answers:

4

I'm sorry but I'm having some trouble implementing Oauth within my app engine python project.

I've been working from http://github.com/tav/tweetapp, but I don't think I have a strong enough grasp on this platform to understand how to implement this class within my main.py I'm building the rest of my app in.

This maybe a feeble attempt, but here is what I have so far:

    twa = twitter_auth

    client = twa.OAuthClient('twitter')

I've created a source folder within my project called "twitter_auth" and that contains a file within it called "twitter_auth.py" which contains the above linked library, and a file called __ init__.py (no space) which is completely empty.

I really have no idea what to do from here :/

A: 

I'm not familiar with that library, but after a quick look and seeing the warning that it is not maintained I'd search for something better. I implemented a simple Twitter connection based on Tornado's auth: see an example of how to make Twitter API calls here (and an authentication example here). In case you don't want to use tipfy, I recommend implementing the python-twitter library in your framework of choice.

moraes
It has a functional running prototype up right now.
tlow
http://twitteroauth.appspot.com/
tlow
+1  A: 

Let me recommend taking a look at the tweepy library and some example tweepy apps. Specifically here: http://github.com/wasauce/tweepy-examples

This shows how to use oauth to authenticate a user: http://github.com/wasauce/tweepy-examples/tree/master/appengine/oauth_example/

Wasauce
ok, I'm going to check these out today, will report back
tlow
+1  A: 

As Hagge said, it sounds like your issue is more with the tweetapp library than with App Engine. However, if you would like to know more about OAuth on App Engine and if I may be allowed to link to myself, my two articles on the topic seem to be reasonably popular.

pr1001
+1  A: 

The tweetapp library was a an early prototype for Twitter OAuth on twitter. Tav did the heavy lifting and I deployed the site http://twitteroauth.appspot.com , using some of the tweetapp library. The actual source of that site is here (I need to update the site to point here): http://github.com/ryanwi/twitteroauth

I am still using it in production, but, it has aged and does not work for all API calls. I'd recommend trying a different, more up to date and maintained library as others have mentioned.

But, take a look at the twitteroauth source if you want to try to get a first attempt working.

These two are on Twitter's list

RyanW