andrei-zgirvaci / Twitch-Farmer

A bot that helps you to get more followers on Twitch
135 stars 38 forks source link

Message: no such element: Unable to locate element: {"method":"xpath","selector":"//input[@value='Log In']"} #2

Closed Maras0830 closed 7 years ago

Maras0830 commented 7 years ago

umm ...

I got the error after execute python3 Twitch-Farmer.py command.

my chrome browser has been opened, but get this error.

output:

Traceback (most recent call last):
  File "Twitch-Farmer.py", line 159, in <module>
    SetUp(proxies[proxy_count], username, password)
  File "Twitch-Farmer.py", line 21, in SetUp
    Login(username, password)
  File "Twitch-Farmer.py", line 69, in Login
    loginButtonElement = driver.find_element_by_xpath(loginButtonXpath)
  File "/usr/local/lib/python3.5/site-packages/selenium/webdriver/remote/webdriver.py", line 293, in find_element_by_xpath
    return self.find_element(by=By.XPATH, value=xpath)
  File "/usr/local/lib/python3.5/site-packages/selenium/webdriver/remote/webdriver.py", line 752, in find_element
    'value': value})['value']
  File "/usr/local/lib/python3.5/site-packages/selenium/webdriver/remote/webdriver.py", line 236, in execute
    self.error_handler.check_response(response)
  File "/usr/local/lib/python3.5/site-packages/selenium/webdriver/remote/errorhandler.py", line 192, in check_response
    raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.NoSuchElementException: Message: no such element: Unable to locate element: {"method":"xpath","selector":"//input[@value='Log In']"}
  (Session info: chrome=55.0.2883.95)
  (Driver info: chromedriver=2.26.436421 (6c1a3ab469ad86fd49c8d97ede4a6b96a49ca5f6),platform=Mac OS X 10.12.1 x86_64)
andrei-zgirvaci commented 7 years ago

Now it should be fixed! :) p.s thx for pull request. I saw it but instead of deleting "loginButtonXpath" I just changed it's value.