2

I am trying to get selenium to use chromedriver on mac.

I have downloaded the mac version of chromedriver and added it to the same folder as my python file. I am then using:

driver = webdriver.Chrome()

however it doesn't seem to be opening.

This works fine in windows but just not working on mac. anyone got any ideas?

Thanks

2 Answers 2

8

You might need to install it with : brew install chromedriver --cask or brew install chromedriver

and then do which chromedriver

You will get the relevant path.

Sign up to request clarification or add additional context in comments.

Comments

4

You either have to provide a path to binary when creating an instance of webdrive.Chrome():

chromedriver = "/path/to/chromedriver/folder"
driver = webdriver.Chrome(chromedriver)

or chromedriver has to be in you PATH. You can add chromedriver to PATH with

export PATH=$PATH:/path/to/chromedriver/folder

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.