Update test shell.
authorJosh Roesslein <jroesslein@gmail.com>
Sat, 31 Oct 2009 07:03:16 +0000 (02:03 -0500)
committerJosh Roesslein <jroesslein@gmail.com>
Sat, 31 Oct 2009 07:03:16 +0000 (02:03 -0500)
tweepyshell.py

index 57de31f515367481f0ba7b11f6155e431be32f48..56127d3916b567d45a1f662030a7f408cc35b10c 100755 (executable)
@@ -4,6 +4,7 @@ import sys
 
 import code
 import tweepy
+from tweepy import API, BasicAuthHandler
 
 """Launch an interactive shell ready for Tweepy usage
 
@@ -17,7 +18,7 @@ if len(sys.argv) != 3:
     print 'Usage: tweepyshell <username> <password>'
     exit(1)
 
-api = tweepy.API.new(auth='basic', username=sys.argv[1], password=sys.argv[2])
+api = API(BasicAuthHandler(username=sys.argv[1], password=sys.argv[2]))
 
 code.interact('<Tweepy shell>', local={'tweepy': tweepy, 'api': api})