问题描述:

  今天因为在学习要使用selenium这个python库,我下载好了selenium,并且也Import成功了,但是在我使用webdirver.chorme()时,却提示PATH路径中没有chromedriver。

解决方法:

  我按照python上运行结果的提示,进入到chromedriver的官网,然后下载了和我的chrome版本对应的chromedirver(我的版本是61,所以下载了2.28版本的chromedriver)。然后将这个文件解压,得到了chromedriver.exe文件,然后将这个文件放到了E:\chromedriver\ 下,所以这个文件的绝对路径就是 E:\chromedriver\chromedriver.exe

  最重要的一步就是将 webdriver.chrome()改成了 webdriver.chrome('E:\chromedriver\chromedriver.exe'),这样问题就解决了。

  

Selenium调用webdriver.chrome()出错的更多相关文章

  1. selenium调用webdriver异常

    使用selenium调用webdriver的时候报错. from selenium import webdriver browser = webdriver.Chrome() browser.get( ...

  2. python利用selenium(webdriver chrome)模拟登陆获取cookie

    (我是在windows下进行实验的) 准备工作: 1.安装python环境. 2.python安装selenium插件(执行以下命令就行).   pip install selenium 3.Wind ...

  3. Python3 + selenium + Chrome浏览器(webdriver.Chrome()报错)

    Python3 + selenium + Chrome浏览器 Error: selenium.common.exceptions.WebDriverException: Message: 'chrom ...

  4. Selenium调用Chrome,Firefox,IE

    C#环境下,使用Selenium调用不同的浏览器,可以使用如下方法: IWebDriver driver = null; string Browser =null; if (Browser.Equal ...

  5. python+selenium浏览器调用(chrome、ie、firefox)

    代码: #coding=utf-8 from selenium import webdriver driver=webdriver.Chrome() #调用chrome浏览器 driver.get(' ...

  6. selenium调用Firefox和Chrome需要注意的一些问题,和出现的报错selenium:expected [object undefined] undefined to be a string

    在高版本selenium下如:selenium3.4.3 1.高版本的selenium需要浏览器安装一些补丁驱动 Firefox:geckodriver 下载网址:http://download.cs ...

  7. python+selenium调用chrome打开网址获取内容

    目录 1,安装selenium和配置chromedriver 2,调用chromedriver打开网页获取网页内容 3,模拟登陆百度云 附录(webdriver版本兼容列表) 通过selenium库, ...

  8. selenium +python webdriver运行时报错cannot find Chrome binary

    今日在公司电脑运行自动化测试脚本,出现cannot find Chrome binary报错 百思不得其解,排错后发现应该是电脑以前有配置driver文件路径,driver所在文件路径已变更,现pyt ...

  9. Python selenium.webdriver.chrome.options.Options() Examples

    The following are 27 code examples for showing how to use selenium.webdriver.chrome.options.Options( ...

随机推荐

  1. Java模式之模板方法模式

    当我们遇到的业务逻辑具有大致相同的方式的时候,我们也许就该将这个业务逻辑抽象出来,采用模板方法,来进行封装我们的代码,提高代码的重用性,以及可维护性.下面是我的一个复习用的案例: 第一步:我们需要一个 ...

  2. 海量数据挖掘MMDS week1: Link Analysis - PageRank

    http://blog.csdn.net/pipisorry/article/details/48579435 海量数据挖掘Mining Massive Datasets(MMDs) -Jure Le ...

  3. shell重定向(大于号,小于号,左右,2>&1,&)

    本文的例子部分是引用网络上的一篇文章. Linux的IO输入输出有三类 Standard Input 代码 0 Standard Output 代码 1 Standard Error 代码 2 举个例 ...

  4. Cocos2D中相关问题提问的几个论坛

    如果和SpriteBuilder相关可以到: http://forum.spritebuilder.com 提问. 如果是Cocos2D的问题,则可以到以下论坛询问: http://forum.coc ...

  5. 【65】Mybatis详解

    Mybatis介绍 MyBatis是一款一流的支持自定义SQL.存储过程和高级映射的持久化框架.MyBatis几乎消除了所有的JDBC代码,也基本不需要手工去设置参数和获取检索结果.MyBatis能够 ...

  6. 如何写好一个UITableView(完整版)

    本文是直播分享的简单文字整理,直播共分为上.下两部分.第一部分:优酷 Or YouTube,第二部分:优酷 Demo 地址:KtTableView 如果你觉得UITableViewDelegate和U ...

  7. #pragma comment(转)

    此文转自微软MSDN.注意这是在Windows上才有的,Linux上可没有. #pragma comment( comment-type [,"commentstring"] ) ...

  8. Hbase replication操作

    1.修改hbase-site.xml文件 <property>  <name>hbase.replication</name>  <value>true ...

  9. C语言算法--统计字符串中单词的个数

    #include <stdio.h> #include <string.h> #include <stdlib.h> int main(void) { int le ...

  10. linux下分割和重组文件

    linux shell命令里的split和cat命令可以轻松完成这两个功能,举个例子来说,比如一个1GB大小的文件foo.zip,以100M为块分割: 分割: split -b 100M -d foo ...