码迷,mamicode.com
首页 > 系统相关 > 详细

mac chromedriver error

时间:2015-12-12 01:28:21      阅读:334      评论:0      收藏:0      [点我收藏+]

标签:

问题一:MAC 使用splinter error

Traceback (most recent call last):
    from splinter.browser import Browser
    b = Browser(driver_name="chrome")
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/splinter/browser.py", line 63, in Browser
    return driver(*args, **kwargs)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/splinter/driver/webdriver/chrome.py", line 28, in __init__
    self.driver = Chrome(chrome_options=options, **kwargs)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/selenium/webdriver/chrome/webdriver.py", line 61, in __init__
    self.service.start()
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/selenium/webdriver/chrome/service.py", line 73, in start
    os.path.basename(self.path), docs_msg)
selenium.common.exceptions.WebDriverException: Message: chromedriver executable needs to be in PATH. Please see https://sites.google.com/a/chromium.org/chromedriver/home

解决办法:

按照其他人的建议:brew install chromedriver  行不通。下载链接已失效。

自己下载zip文件  地址:http://chromedriver.storage.googleapis.com/index.html

 

接着 

$unzip chromedriver_map32.zip 

$mv chromedriver /usr/local/bin

$cd /usr/local/bin

$chmod a+x chromedirver

完事!

mac chromedriver error

标签:

原文地址:http://www.cnblogs.com/tangkaixin/p/5040565.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!