Created
May 14, 2009 00:59
-
-
Save rlr/111409 to your computer and use it in GitHub Desktop.
py script to find out which twitter users aren't following your back
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from twitter.api import Twitter | |
USERNAME = 'r1cky' # set to your/any username | |
twitter = Twitter() # username/password not required for these calls | |
friends = twitter.friends.ids(screen_name=USERNAME) | |
followers = twitter.followers.ids(screen_name=USERNAME) | |
guilty = [x for x in friends if x not in followers] | |
print "There are %s tweeps you follow who do not follow you" % len(guilty) | |
for user_id in guilty: | |
user = twitter.users.show(user_id=user_id) | |
print "%s follows %s and has %s followers." % \ | |
(user['name'], user['friends_count'], user['followers_count'] ) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment