Sorry for my English. I use the Instaloader-Master to download instagram profiles. Until now, I used downloading through the command line, but I decided to switch to download through Python, because of the ability to bypass the blocking of the account, etc. Is my code set correctly for downloading the entire contents of the profile? And how to enable RateController?
import instaloader
USERNAME = 'ACCOUNT_NAME'
PASSWORD = 'PASSWORD'
SESSION_FILENAME = 'SESSION'
PROFILE = "nurgularikan.tr"
DIR = "{target}"
Name = "{date:%Y-%m-%d %H-%M-%S} {mediaid}_{owner_id}"
L = instaloader.Instaloader(dirname_pattern=DIR, filename_pattern=Name)
#L.login(USERNAME, PASSWORD)
L.load_session_from_file(username=USERNAME, filename=SESSION_FILENAME)
print('LOGIN.')
profile = instaloader.Profile.from_username(L.context, PROFILE)
for post in profile.get_posts():
L.download_post(post, target=profile.username)
filename = profile.username + '/' + L.format_filename(post, target=profile.username)
you can use this code to download profiles easily.