I want to specify the path to a file in a python project on the pythonanywhere site. Unfortunately, I am getting an error. Here are pictures of the folder and console
Code:
driver = uc.Chrome(options=options, driver_executable_path="/user/KraKoff/files/home/KraKoff/chromedriver.exe")
CodePudding user response:
Do not specify the chromedriver path on PythonAnywhere. It is not necessary.
CodePudding user response:
You are using pythonanywhere
So you need to download and use the ChromeDriver executable of linux type instead of the windows type and you need to pass the absolute path without the extension i.e. .exe
.
Solution
Your effective line of code will be:
driver = uc.Chrome(options=options, driver_executable_path="/user/KraKoff/files/home/KraKoff/chromedriver")