Python "chromedriver" executable needs to be in PATH














































Python "chromedriver" executable needs to be in PATH



Python 'chromedriver' executable needs to be in PATH

ChromeDriver is a separate executable that Selenium WebDriver uses to control Chrome. It is maintained by the Chromium team with help from WebDriver contributors. 

To setup selenium webdriver, we need to install Chromedriver and set the path.

1. Run following command in Command Prompt install webdriver:

pip install chromedriver 

2. Find the path it install and copy it, Shown below.

pip show chromedriver



3. Now add this path in "Environment variables"  with adding "/chromedriver" .
The example is given below:-



4. After adding it, check in Command Prompt by writing 'chromedriver', Given Below.



So You have Successfully installed and set the Executable Path.



Method 2.

if you are installing Chromedriver for Web Automation using selenium, So in python there are other library called
'webdriver_manager' for every webdriver.

let's work with it

install the library using Command Prompt by following command:

pip install webdriver-manager

Here the Example for launch the chromedriver using selenium and webdriver-manager.
Example:

# Import webdriver for automation
from selenium import webdriver

# Importing the ChromeDriver class for handling webdriver
from webdriver_manager.chrome import ChromeDriverManager

driver = webdriver.Chrome(ChromeDriverManager().install()) # diver

output:




More Articles of Abhishek Kushwaha:

Name Views Likes
python pocketsphinx installation on windows 567 5
python error handling 252 1
Python ModuleNotFoundError: No module named "selenium" 1064 1
python3 UnBoundLocalError: local variable referenced before assignment 627 1
Python ModuleNotFoundError: No module named PIL 3477 1
python pyAudio failed to install Windows 10 1076 1
Python program to put all word in a list from a string 196 1
Python program to convert string into a list 241 1
python AttributeError: Could not find PyAudio 1124 2
python ModuleNotFoundError: No module named pandas 13960 1
Python ImportError: numpy.core.multiarray failed to import 2112 2
ModuleNotFoundError: No module named "numpy" 2526 1
Python "chromedriver" executable needs to be in PATH 5492 1
Python ModuleNotFoundError: No module named "mysql" 1395 1
ModuleNotFoundError: No module named "pocketsphinx" 568 1
pip is not recognized as an internal or external command 2305 1
ModuleNotFoundError: No module named 789 7
Python Program to Find the Common Ancestor and Print the Path 294 2
ModuleNotFoundError No module named 45 8
Python The best way to determine exception type 230 1
Python IndentationError unindent does not match any outer indentation level 472 1
Python 3 ModuleNotFoundError No module named "cv2" 29758 3
Testing PurPose 220 10
Printing Without A Newline In Python2 182 2
Printing Without A Newline In Python3 207 2
Python Program to Search an Element in a Tree Non-Recursively 364 2
Python Program to Search an Element in a Tree Recursively 486 2
Python Program to Implement Doubly Linked List using Singly Linked List 241 2
Python Program to Find the Power of a Number Using Recursion 157 7
Python Program to Construct A Balanced Binary Tree using Sorted Array : 393 2
Find Numbers of even number in the given list Python Style 204 2

Comments