相关疑难解决方法(0)

org.openqa.selenium.WebDriverException:未知错误:尝试启动Chrome浏览器时,DevToolsActivePort文件不存在

我正在尝试使用URL启动chrome,浏览器启动,之后它什么都不做.

我在1分钟后看到以下错误:

Unable to open browser with url: 'https://www.google.com' (Root cause: org.openqa.selenium.WebDriverException: unknown error: DevToolsActivePort file doesn't exist
  (Driver info: chromedriver=2.39.562718 (9a2698cba08cf5a471a29d30c8b3e12becabb0e9),platform=Windows NT 10.0.15063 x86_64) (WARNING: The server did not provide any stacktrace information)
Run Code Online (Sandbox Code Playgroud)

我的配置:

Chrome:66 ChromeBrowser:2.39.56

PS在Firefox中一切正常

selenium google-chrome webdriver selenium-chromedriver selenium-webdriver

120
推荐指数
16
解决办法
11万
查看次数

Selenium python:无法连接到服务%s"%self.path

我正在尝试使用python脚本运行selenium测试,但是在执行测试时我收到以下错误:

Traceback (most recent call last):
File "/var/www/html/selenium-scripts/example.py", line 13, in <module>
driver = webdriver.Chrome()
File "/usr/local/lib/python2.7/site-packages/selenium/webdriver/chrome/webdriver.py", line 61, in __init__self.service.start()
File "/usr/local/lib/python2.7/site-packages/selenium/webdriver/common/service.py", line 88, in start
raise WebDriverException("Can not connect to the Service %s" % self.path)
selenium.common.exceptions.WebDriverException: Message: Can not connect to the Service chromedriver
Run Code Online (Sandbox Code Playgroud)

请告知如何解决这个问题

python selenium

5
推荐指数
1
解决办法
4876
查看次数