rhiever / TwitterFollowBot

A Python bot that automates several actions on Twitter, such as following users and favoriting tweets.
GNU General Public License v3.0
1.31k stars 447 forks source link

Unfollow order #111

Open xel1983 opened 8 years ago

xel1983 commented 8 years ago

Hi does anyone know how the bot unfollows. Does it unfollow from the oldest followed to the latest? It appears to be adding the latest follow to the top of the followed list and then moving them from the top to the followed list top too. Maybe I'm wrong, but if this is the case would reversing the order cause any trouble with the syncing of the files or anything?

Many thanks in advance for input.

iandouglas commented 8 years ago

The Python code is using sets pretty heavily, which simple track uniqueness in an unordered/unsorted form. At several places in the code it reads the followers/following files into a set, which can get rearranged at any time.

To track what you're suggesting, you'd probably want to push the data into a database with a timestamp and then unfollow people in an ascending date order to get the oldest first.