Instapy: time between likes

Created on 23 Mar 2018  路  6Comments  路  Source: timgrossmann/InstaPy

hi

for instapy, what's the default time between likes and how to change it to the value that I want

wontfix

Most helpful comment

@lucanello sleep_delay won't work with like_by_tags, because it's not supported like_by_tags function in the instapy.py script. You'll have to add the following to the def like_by_tags function in the instapy.py file.

Here:

def like_by_tags(self,
tags=None,
amount=50,
media=None,
skip_top_posts=True,
use_smart_hashtags=False,
interact=False,
sleep_delay=60):

And here before the links = get_links_for_tag

        try:
            sleep(sleep_delay) 
            links = get_links_for_tag(self.browser,
                                      tag,
                                      amount,
                                      self.logger,
                                      media,
                                      skip_top_posts)

All 6 comments

Welcome @emyabdel. You can change the delay with the sleep_delay=60 argument. Just set any time in seconds you wish.

For example:

session.follow_user_followers(['friend1', 'friend2', 'friend3'], amount=10, randomize=False, sleep_delay=60)

as shown in the README.md file.

Thanks but i want the delay between likes and not between follow

Just add the sleep_delay argument to the like function.

ok thank you

@lucanello sleep_delay won't work with like_by_tags, because it's not supported like_by_tags function in the instapy.py script. You'll have to add the following to the def like_by_tags function in the instapy.py file.

Here:

def like_by_tags(self,
tags=None,
amount=50,
media=None,
skip_top_posts=True,
use_smart_hashtags=False,
interact=False,
sleep_delay=60):

And here before the links = get_links_for_tag

        try:
            sleep(sleep_delay) 
            links = get_links_for_tag(self.browser,
                                      tag,
                                      amount,
                                      self.logger,
                                      media,
                                      skip_top_posts)

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

If this problem still occurs, please open a new issue

Was this page helpful?
0 / 5 - 0 ratings

Related issues

CodeMaster1 picture CodeMaster1  路  3Comments

wyvers picture wyvers  路  3Comments

thisishotdog picture thisishotdog  路  3Comments

tibor picture tibor  路  3Comments

n0sw34r picture n0sw34r  路  3Comments