swaaz / InstaBot

Instagram bot built using Python and Selenium
37 stars 13 forks source link

Element <button class="sqdOP L3NKy y3zKF " type="submit"> is not clickable at point (844,379) because another element <div class="piCib"> obscures it #32

Closed Sudge32 closed 3 years ago

Sudge32 commented 3 years ago

Hey there, I have this strange error. Maybe you can help me?

Traceback (most recent call last): File "C:\Users\user\Downloads\InstaBot-master\program.py", line 240, in <module> main() File "C:\Users\user\Downloads\InstaBot-master\program.py", line 219, in main bot = Instabot(username,password) File "C:\Users\user\Downloads\InstaBot-master\program.py", line 32, in __init__ self.driver.find_element_by_xpath('//button[@type="submit"]').click() File "C:\Users\user\AppData\Local\Programs\Python\Python39\lib\site-packages\selenium\webdriver\remote\webelement.py", line 80, in click self._execute(Command.CLICK_ELEMENT) File "C:\Users\user\AppData\Local\Programs\Python\Python39\lib\site-packages\selenium\webdriver\remote\webelement.py", line 633, in _execute return self._parent.execute(command, params) File "C:\Users\user\AppData\Local\Programs\Python\Python39\lib\site-packages\selenium\webdriver\remote\webdriver.py", line 321, in execute self.error_handler.check_response(response) File "C:\Users\user\AppData\Local\Programs\Python\Python39\lib\site-packages\selenium\webdriver\remote\errorhandler.py", line 242, in check_response raise exception_class(message, screen, stacktrace) selenium.common.exceptions.ElementClickInterceptedException: Message: Element <button class="sqdOP L3NKy y3zKF " type="submit"> is not clickable at point (844,379) because another element <div class="piCib"> obscures it

Greetings and thanks in advance

swaaz commented 3 years ago

@Sudge32 Hello, Thanks a lot for letting me know about that bug. This is due to a change in the Instagram front end. I will fix it ASAP. 💯

swaaz commented 3 years ago

@autumnlewjb Wanna give a try?

autumnlewjb commented 3 years ago

@swaaz Ya sure, the problem should have happened during the login process. However, I am able to login without any errors so I am not really sure where the error is.
My guess is that the error is probably situational where it happens because something is covering the login button. I think what I can do is to add a wait statement before clicking the login button.

swaaz commented 3 years ago

@autumnlewjb The error was in the button which is supposed to close following and followers pop up. I fixed that bug but there is one more bug. When you check for followers and following, it will also take the names of people who are under suggestion. This will give the wrong result when we compare followers and following. I have pushed the code so try to debug.