title: Using xAuth from python using tweepy
body: <p>I am trying to write a twitter client application in python. I would like to use xAuth for authentication. My choice on the library is tweepy, because it seems that it knows everything I need.</p>
  
  <p>Here is my problem:</p>
  
  <pre><code>&gt;&gt;&gt; import tweepy
  &gt;&gt;&gt; auth = tweepy.OAuthHandler(CONSUMER_KEY, CONSUMER_SECRET)
  &gt;&gt;&gt; auth.get_xauth_access_token('username', 'password')
  Traceback (most recent call last):
    File "&lt;stdin&gt;", line 1, in &lt;module&gt;
    File "tweepy/auth.py", line 152, in get_xauth_access_token
      raise TweepError(e)
  tweepy.error.TweepError: HTTP Error 401: Unauthorized
  </code></pre>
  
  <p>The username and the password is correct, I can log in with them. The CONSUMER_{KEY,SECRET} also valid, I copypasted them from the page of my application.</p>
  
  <p>Do you have any idea why the code above fails?</p>