parik
parik

Reputation: 2415

WebDriverException: Message: chrome not reachable

I use Selenium Python, when I run my crawler I got this error

WebDriverException: Message: chrome not reachable
  (Driver info: chromedriver=2.9.248304,platform=Linux 3.16.0-4-amd64 x86_64)

I read this question

I downloaded chromedriver (binary) and I copy/paste it to /usr/bin I tried by

driver = webdriver.Chrome('/usr/bin/chromedriver')

but I have the same error

Upvotes: 1

Views: 12855

Answers (1)

pelican
pelican

Reputation: 6224

In your protractor.configuration file, if you have the following:

capabilities: {
    'browserName': 'chrome',
    'chromeOptions': {
      'binary': 'path/to/chromedriver.exe';
    }   },

Then please remove that binary and instead point to the chromdriver like this:

//protractor.conf.js
chromeDriver: "C:/path/to/chromedriver.exe",
capabilities: {
    'browserName': 'chrome',
    'chromeOptions': {

    }
  },

Notice how I removed the 'binary' argument from the capabilities and added the "chromedriver:" attribute.

That worked for me in removing that annoying error that says "

    UnknownError: chrome not reachable
        28-Jul-2016 10:16:57      
    (Driver info: chromedriver=2.19.346078 (6f1f0cde889532d48ce8242342d0b84f94b114a1),
platform=Windows NT 10.0 x86_64)
 (WARNING: The server did not provide any stacktrace information)

Lastly makes sure you update both chromedriver and seleniumServer like this:

webdriver-manager update

OR Run this command below to update to a SPECIFIC chromedriver version i.e v2.24 as of 10/04/2016:

webdriver-manager update --versions.chrome 2.24

if it says that the command is not recognized, then add it to your PATH in windows environment variable. The webdriver-manager generally sits in the Protractor folder which you can get with npm install protractor

Upvotes: 1

Related Questions