I have developed a python script for selenium automation. Which is automatically open the selenium chrome browser and login into a particular website. It works perfect in the localhost server. Now I deployed it into the cpanel server by following this tutorial. But when I start to run it it says 500 Internal Server Error
.
options = Options()
options.add_argument("start-maximized")
options.add_argument("disable-infobars")
options.add_argument("--disable-extensions")
options.add_argument("--headless")
browser = webdriver.Chrome(options=options, executable_path='chromedriver')
wait = WebDriverWait(browser, 10)
error is causing fro the above code.
I checked with the error log
selenium.common.exceptions.WebDriverException: Message: 'chromedriver.exe' executable needs to be in PATH. Please see https://sites.google.com/a/chromium.org/chromedriver/home
But chromedriver
and the script are in the same directory
I added option('--headless')
in the code
please help me to overcome this error.
I'm very beginner in cpanel