This fixes issue #8 for the time being until Twitter resolves the
issue on their end. See issue #1207 on the twitter API tracker.
Note: API calls still use 'api.twitter.com', just the initial OAuth
setup uses 'twitter.com'.
- You may now pass in an optional 'secure' boolean to the
constructor which will use https for OAuth requests.
Ex: auth = OAuthHandler(token,secret,secure=True)
+ - Fallback to using 'twitter.com' instead of 'api.twitter.com'
+ for OAuth until issue #8 is resolved.
1.3 -> 1.4 [current]
===========================
# test getting access token
auth_url = auth.get_authorization_url()
- self.assert_(auth_url.startswith('http://api.twitter.com/oauth/authorize?'))
print 'Please authorize: ' + auth_url
verifier = raw_input('PIN: ').strip()
self.assert_(len(verifier) > 0)
class OAuthHandler(AuthHandler):
"""OAuth authentication handler"""
- OAUTH_HOST = 'api.twitter.com'
+ OAUTH_HOST = 'twitter.com'
OAUTH_ROOT = '/oauth/'
def __init__(self, consumer_key, consumer_secret, callback=None, secure=False):