title: python-twitter in google app engine
body: <p>I am trying to use python-twitter api in GAE. 
  I need to import Oauth2 and httplib2. </p>
  
  <p>Here is how I did</p>
  
  <p>For OAuth2, I downloaded github.com/simplegeo/python-oauth2/tree/master/oauth2. For HTTPLib2, I dowloaded code.google.com/p/httplib2/wiki/Install and extracted folder python2/httplib2 to project root folder. </p>
  
  <p>my views.py</p>
  
  <pre><code>import twitter
  
  
  def index(request):
    api = twitter.Api(consumer_key='XNAUYmsmono4gs3LP4T6Pw',consumer_secret='xxxxx',access_token_key='xxxxx',access_token_secret='iHzMkC6RRDipon1kYQtE5QOAYa1bVfYMhH7GFmMFjg',cache=None)
  
  
    return render_to_response('fbtwitter/index.html')
  </code></pre>
  
  <p>I got the error <a href="http://paste.shehas.net/show/jbXyx2MSJrpjt7LR2Ksc" rel="nofollow">paste.shehas.net/show/jbXyx2MSJrpjt7LR2Ksc</a></p>
  
  <pre><code>AttributeError
  
  AttributeError: 'module' object has no attribute 'SignatureMethod_PLAINTEXT'
  Traceback (most recent call last)
  
      File "D:\PythonProj\fbtwitter\kay\lib\werkzeug\wsgi.py", line 471, in __call__
  
      return app(environ, start_response)
  
      File "D:\PythonProj\fbtwitter\kay\app.py", line 478, in __call__
  
      response = self.get_response(request)
  
      File "D:\PythonProj\fbtwitter\kay\app.py", line 405, in get_response
  
      return self.handle_uncaught_exception(request, exc_info)
  
      File "D:\PythonProj\fbtwitter\kay\app.py", line 371, in get_response
  
      response = view_func(request, **values)
  
      File "D:\PythonProj\fbtwitter\fbtwitter\views.py", line 39, in index
  
      access_token_secret='iHzMkC6RRDipon1kYQtE5QOAYa1bVfYMhH7GFmMFjg',cache=None)
  
      File "D:\PythonProj\fbtwitter\fbtwitter\twitter.py", line 2235, in __init__
  
      self.SetCredentials(consumer_key, consumer_secret, access_token_key, access_token_secret)
  
      File "D:\PythonProj\fbtwitter\fbtwitter\twitter.py", line 2264, in SetCredentials
  
      self._signature_method_plaintext = oauth.SignatureMethod_PLAINTEXT()
  
      AttributeError: 'module' object has no attribute 'SignatureMethod_PLAINTEXT'
  </code></pre>
  
  <p>It seems I did not import Oauth2 correctly when I tracked the error in twitter.py</p>
  
  <pre><code>self._signature_method_plaintext = oauth.SignatureMethod_PLAINTEXT()
  </code></pre>
  
  <p>I even go to twitter.py and add <code>import oauth2 as oauth</code> but it couldnt solve the problem</p>
  
  <p>Can anybody help?</p>