0

专家们,

我有以下配置

nvm - 0.33.0
node - 7.5.0
npm - 4.1.2
webdriver-manager - 12.0.6

我在公司代理背后,我使用cntlm。当我运行以下命令时

webdriver-manager update --standalone --ignore_ssl --verbose --proxy="http://localhost:3190/"

我得到以下输出

webdriver-manager: using global installed version 12.0.6
[15:08:27] I/http_utils - ignoring SSL certificate
[15:08:27] I/http_utils - ignoring SSL certificate
[15:08:27] I/http_utils - ignoring SSL certificate
(node:4132) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: response status code is not 200
(node:4132) DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
[15:08:28] I/update - chromedriver: unzipping chromedriver_2.33.zip
[15:08:28] I/update - chromedriver: setting permissions to 0755 for /home/ua70vv/.nvm/versions/node/v7.5.0/lib/node_modules/webdriver-manager/selenium/chromedriver_2.33
[15:08:29] I/http_utils - ignoring SSL certificate
[15:08:34] I/update - geckodriver: unzipping geckodriver-v0.19.0.tar.gz
[15:08:34] I/update - geckodriver: setting permissions to 0755 for /home/ua70vv/.nvm/versions/node/v7.5.0/lib/node_modules/webdriver-manager/selenium/geckodriver-v0.19.0

我看到有一个警告。

在此之后,当我尝试运行“webdriver-manager start”时,我仍然收到以下错误消息

E/start - Selenium Standalone is not present. Install with webdriver-manager update --standalone

请建议这里的错误是什么。

提前致谢!

4

2 回答 2

1
--ignore_ssl                Ignore SSL certificates
--proxy                     Proxy to use for the install or update command

喜欢webdriver-manager update --ignore_ssl

这将解决您的问题。

于 2018-10-17T06:18:01.603 回答
0

似乎standalone.jar 下载站点不可用。 https://selenium-release.storage.googleapis.com/

您可以使用 java cmd 启动 selenium 服务器,将以下内容保存到窗口上的 start-selenium-server.cmd 文件中,并将版本和 driver_home 更改为您的。双击它运行。

set standalone_version=3.4.0
set chromedriver_version=2.32
set geckodriver_version=v0.19.0

set driver_home=C:\Tool\npm-global\node_modules\protractor\node_modules\webdriver-manager\selenium

java -Dwebdriver.chrome.driver=%driver_home%\chromedriver_%chromedriver_version%.exe -Dwebdriver.gecko.driver=%driver_home%\geckodriver-%geckodriver_version%.exe -jar %driver_home%\selenium-server-standalone-%standalone_version%.jar -port 4444
于 2017-10-18T14:17:07.567 回答