Example #1
0
	def checkFriendshipUsername (self,userNameA, userNameB):
		#RETURNS TRUE IF USER_A FOLLOWS USER_B. It has to be symmetrical
		twitter = Twython()
		existsAB = twitter.checkIfFriendshipExists (screen_name_a = userNameA, screen_name_b = userNameB)
		existsBA = twitter.checkIfFriendshipExists (screen_name_a = userNameB, screen_name_b = userNameA)
		print "AB : %s" %(existsAB)
		print "BA : %s" %(existsBA)
		if (existsAB == True and existsBA == True):
			friendship = True	
			print "Friendship TRUE"
		else:
			friendship = False
			print "Friendship FALSE"	
		print "friendship between (%s, %s) %s" %(userNameA, userNameB, friendship)
		return friendship