![]() |
Getting error 'geckodriver' executable needs to be in PATH. - Printable Version +- Python Forum (https://python-forum.io) +-- Forum: Python Coding (https://python-forum.io/forum-7.html) +--- Forum: Web Scraping & Web Development (https://python-forum.io/forum-13.html) +--- Thread: Getting error 'geckodriver' executable needs to be in PATH. (/thread-7437.html) |
Getting error 'geckodriver' executable needs to be in PATH. - sumandas89 - Jan-10-2018 I am executing the following python program, and getting error mentioned "'geckodriver' executable needs to be in PATH. " from selenium import webdriver from selenium.webdriver.common.keys import Keys driver = webdriver.Firefox() driver.get("http://www.python.org") assert "Python" in driver.title elem = driver.find_element_by_name("q") elem.clear() elem.send_keys("pycon") elem.send_keys(Keys.RETURN) assert "No result found." not in driver.page_source driver.close() I want to know that why the error is coming and what is the resolution of this error? Please explain.I am using fedora operating system and pycharm editor. RE: Getting error 'geckodriver' executable needs to be in PATH. - squenson - Jan-10-2018 http://lmgtfy.com/?q=python+geckodriver+path RE: Getting error 'geckodriver' executable needs to be in PATH. - sumandas89 - Jan-11-2018 Download the proper geckodriver depending upon your operating system and System Architecture from the url here - geckodriver Now follow the below steps - Extract the geckodriver file from the downloaded zip file. Now depending upon your operating system do the following. For Linux system : Open terminal and login as root user. copy/move the extracted geckodriver to bin direcctory. In my case I moved the file to /usr/bin directory. Because the driver finds geckodriver binary in '/usr/bin' path and the problem is solved now. To move the file inside bin directory use command like - $mv 'geckodriver binary source path' 'destination path' destination path should be the binary folder path as per user system. For Windows System : Just execute the the extracted geckodriver binary file. |