deleted in the profile).įrom glob import glob from sys import argv from os import chdir from instaloader import Instaloader, Post, Profile, load_structure_from_file # Instaloader instantiation - you may pass additional arguments to the constructor here L = Instaloader () # If desired, load session previously saved with `instaloader -l USERNAME`: #L.load_session_from_file(USERNAME) try : TARGET = argv except Inde圎rror : raise SystemExit ( "Pass profile name as argument!" ) # Obtain set of posts that are on hard disk chdir ( TARGET ) offline_posts = set ( filter ( lambda s : isinstance ( s, Post ), ( load_structure_from_file ( L. List of posts which are offline but not online (i.e. It outputsĪ list of posts which are online but not offline (i.e. This script uses Instaloader to obtain a list of currently-online Instagram andĬompares it with the set of posts that you already have downloaded. Profile.get_followers(), Instaloader.load_session_from_file(),ĭiscussed in Issue #120. See also Profile.get_posts(), Post.get_likes(), get_followers ()) ghosts = followers - likes print ( "Storing ghosts into file." ) with open ( "inactive-users.txt", 'w' ) as f : for ghost in ghosts : print ( ghost. context, PROFILE ) likes = set () print ( "Fetching likes of all posts of profile. load_session_from_file ( USER ) profile = instaloader. Instaloader () USER = "your_account" PROFILE = USER # Load session previously saved with `instaloader -l USERNAME`: L.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |