-
Notifications
You must be signed in to change notification settings - Fork 822
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WSL cannot open chromedriver.exe in /mnt/c #4932
Comments
There is no repro here, but if your scenario was working in WSL1 and not WSL2 that usually is because of loss of |
@YiRuChenbilibili I want to use Initially I thought that you can't call I have Chrome Version 80.0.3987.149 (Official Build) (64-bit), on Windows 10, and I'm using ChromeDriver 80.0.3987.106 and I'm calling it via WSL with Since I can't get this to work I'm looking now to set this up running Maven from Windows rather than WSL. Any help appreciated. Thanks. |
I simply try this in WSL(version 1): driver = webdriver.Chrome(executable_path="/mnt/c/Program Files (x86)/Microsoft Visual Studio/Shared/Python36_64/Scripts/chromedriver.exe") driver.get("http://www.baidu.com") print(driver.page_source) driver.quit() And it can work. |
The only issue with this, is that |
I just updated my wsl to wsl2. In wsl I can easily use my chromedriver by set (chrome_driver = "/mnt/c/Program Files (x86)/Google/Chrome/Application/chromedriver.exe")then driver = webdriver.Chrome(chrome_driver)
But after I started to use WSL2.It raises the problems like this:
Traceback (most recent call last):
File "", line 1, in
File "/home/chen/.local/lib/python3.6/site-packages/selenium/webdriver/chrome/webdriver.py", line 73, in init
self.service.start()
File "/home/chen/.local/lib/python3.6/site-packages/selenium/webdriver/common/service.py", line 104, in start
raise WebDriverException("Can not connect to the Service %s" % self.path)
selenium.common.exceptions.WebDriverException: Message: Can not connect to the Service /mnt/c/Program Files (x86)/Google/Chrome/Application/chromedriver.exe
what should I do?Or it's just not support?
The text was updated successfully, but these errors were encountered: