selenium.common.exceptions.WebDriverException: Message: unknown Error: cannot find Chrome binary
使用Chrome浏览器时,经常会遇到以下报错:浏览器没有调用起来
selenium.common.exceptions.WebDriverException: Message: unknown Error: cannot find Chrome binary
通常由两种问题引起的:
1.ChromeDriver.exe驱动有问题(包括版本,路径等等)
2.Chrome.exe本身有问题。
解决方案:三个
1.指定chromedriver.exe驱动绝对路径
driver = webdriver.Chrome(r'd:\xxx\chromedriver.exe')
2.添加chrome.exe到系统path环境变量
3.在代码中指定chrome.exe绝对路径。设置binary_location属性
option = webdriver.ChromeOptions()
option.binary_location=r'C:\Users\Administrator\AppData\Local\Google\Chrome\Application\chrome.exe'
driver = webdriver.Chrome()
driver.get('https://www.baidu.com')
selenium.common.exceptions.WebDriverException: Message: unknown Error: cannot find Chrome binary的更多相关文章
- robotframework执行用例时,报错selenium.common.exceptions.WebDriverException: Message: unknown error: cannot get automation extension from unknown error: page could not be found: chrome-extension://aapnijgdinl
在用robotframework编写移动端测试用例(用chrome浏览器模拟手机浏览器),执行用例时, 报错selenium.common.exceptions.WebDriverException: ...
- 【Python + Selenium】初次用IE浏览器之报错:selenium.common.exceptions.WebDriverException: Message: Unexpected error launching Internet Explorer. Protected Mode settings are not the same for all zones.
初次用IE浏览器运行自动化程序时,报错:selenium.common.exceptions.WebDriverException: Message: Unexpected error launchi ...
- 【Selenium】【BugList6】调用IE,未启用保护模式,报:selenium.common.exceptions.WebDriverException: Message: Unexpected error launching Internet Explorer. Protected Mode settings are not the same for all zones.
>>> driver = webdriver.Ie() 解决方法: 1.打开Ie浏览器 , 工具 ->Internet选项 ->安全 2.去掉4个区域的安全保护模式
- selenium启动IE浏览器报错:selenium.common.exceptions.WebDriverException: Message: Unexpected error launching Internet Explorer. Protected Mode settings are not the same for all zones. Enable Protected Mode mu
意思是浏览器的保护模式设置不一致所导致 解决方案-->修改IE设置 将所有区域的保护模式勾选去掉即可
- selenium.common.exceptions.WebDriverException: Message: u'unknown error: cannot get automation extension\nfrom unknown error: page could not be found: chrome-extension://aapnijgdinlhnhlmodcfapnahmbfeb
Python2.7 selenium3.4.1在使用chrome driver时报错:selenium.common.exceptions.WebDriverException: Message: u ...
- Appium问题解决方案(8)- selenium.common.exceptions.WebDriverException: Message: An unknown server-side error occurred while processing the command. Original error: Could not sign with default certificate.
背景 运行时代码报错: selenium.common.exceptions.WebDriverException: Message: An unknown server-side error occ ...
- centos7 selenium.common.exceptions.WebDriverException: Message: 'chromedriver' executable needs to be in PATH
1.查看安装的chrome浏览器版本 2.查看版本对应的驱动 https://sites.google.com/a/chromium.org/chromedriver/downloads 下载后拷贝到 ...
- selenium使用遇到的问题(selenium.common.exceptions.WebDriverException: Message: 'chromedriver' executable needs to be in PATH.)
1.安装pip3 install selenium 2.使用browser=webdriver.Chrome()时报错 :selenium.common.exceptions.WebDriverExc ...
- python+selenium,打开浏览器时报selenium.common.exceptions.WebDriverException: Message: 'chromedriver' executable needs to be in PATH
有一年多没写web自动化了,今天搭建环境的时候报了一个常见错误,但是处理过程有点闹心,报错就是常见的找不到驱动<selenium.common.exceptions.WebDriverExcep ...
随机推荐
- C语言 · 勾股数
勾股数 勾股定理,西方称为毕达哥拉斯定理,它所对应的三角形现在称为:直角三角形. 已知直角三角形的斜边是某个整数,并且要求另外两条边也必须是整数. 求满足这个条件的不同直角三角形的个数. [数据格式] ...
- 微信jssdk常见错误及解决方法
调用config 接口的时候传入参数 debug: true 可以开启debug模式,页面会alert出错误信息.以下为常见错误及解决方法: invalid url domain当前页面所在域名与使用 ...
- 关于Retrofit网络请求URL中含有可变参数的处理
开题:在此默认各位看官对Retrofit.以及Okhttp已经有过一定的了解及应用,所以今天我们不谈基础入门的东西,今天我们谈在Retrofit请求接口管理类中URL参数含有动态参数的处理方式.一般我 ...
- C#WebService服务在Windows7的部署
(一)C#WebService服务在Windows7的部署 一.在控制面板,程序与卸载中安装IIS组件. 二.IIS无法显示WebService的.asmx文件.解决办法:注:(这里可以不用考虑,直 ...
- 【转】wpf 模板选择器DataTemplateSelector及动态绑定,DataTemplate.Triggers触发器的使用
通常,如果有多个 DataTemplate 可用于同一类型的对象,并且您希望根据每个数据对象的属性提供自己的逻辑来选择要应用的 DataTemplate,则应创建 DataTemplateSelect ...
- linux系统下键盘按键的重新映射——xmodmap工具和xev工具
大家会不会有时候,感觉键盘上的某几个键用起来不是很方便,打字打久了很容易手指头疼呢? 例如大家使用vim编辑器时, 经常需要使用到esc键,而该键在左上角,很不方便的.再比如写程序的时候,经常会使用到 ...
- thinkphp3.2在nginx下的配置
最近一直没用nginx 昨天将tp3.2的项目部署到Ubuntu下的nginx下,发现忘记怎么配置的了 特将配置方式记录下来,以方便日后查找 服务器nignx 配置文件 server { listen ...
- nginx通过反向代理实现未备案域名访问详解
本方法实现前提是8123端口(也可以是其他端口)面对互联网打开.server里面监听80端口,然后反向代理8123端口.1.其中server_name部分是我的域名可以替换成其他想要的域名2.8123 ...
- Linux 依据关键字查找正在运行的进程
ps aux |grep tm1s
- k8s(5)-拓展服务
在之前我们创建了一个部署,然后通过服务公开它.部署只创建了一个Pod来运行我们的应用程序.当流量增加时,我们需要扩展应用程序以满足用户需求. 通过更改部署中的副本数来完成扩展. 1. 拓展部署 这里将 ...