AbhilashDatta / InstagramBot

An Instagram bot that can mass text users, receive and read a text, and store it somewhere with user details.
https://instagrambot0.yolasite.com/
MIT License
20 stars 8 forks source link

I cannot login to Instagram properly with the bot #1

Open ilyadynin opened 3 years ago

ilyadynin commented 3 years ago

Always when I run the bot and it tries to login to Instagram with chromedriver in a new instance, there always is a message like "Save login information for this browser" and then I get the message "Unable to login" and the bot stops

AbhilashDatta commented 3 years ago

I never encountered that while developing, so I didn't include that in the pipeline or handled any exceptions for it. You have to disable the password-saving feature permanently for your new chrome instances. You may get help here : https://stackoverflow.com/questions/46595113/how-to-disable-chromes-save-password-popup-in-selenium-webdriver-python If any further problem persists, feel free to contact me :)

ilyadynin commented 3 years ago

Where do I have to add this one :)? I mean in which file I am new to Python, so I have a lot of troubles... I am sorry xd

AbhilashDatta commented 3 years ago

You can add the code in the constructor of the Bot class.


class Bot():

    def __init__(self):
        chrome_opt = webdriver.ChromeOptions()
        prefs = {"credentials_enable_service", False}
        prefs = {"profile.password_manager_enabled" : False}
        chrome_opt.add_experimental_option("prefs", prefs)

        self.driver = webdriver.Chrome(chrome_options=chrome_opt)
        self.driver.maximize_window()