3

I am having so many problems with the webdriver for webscraping with selemium. The chromedriver is already installed and placed in the same folder as python file. All the suggestions that seem to load the the jupyter cell for few seconds are rejected after to this following message: chromedriver cannot opened because the developer cannot be verififed where I used homebrew to download them. Here my code:

from bs4 import BeautifulSoup as soup
import pandas as pd
from selenium import webdriver

my_url='google.com'
driver= webdriver.Chrome()

I am now trying to solve this problem by downloading chromium but I have that status code was 9 error and that pop up telling me that my code cannot be trusted.

Camue
  • 469
  • 7
  • 17

3 Answers3

8
xattr -d com.apple.quarantine /usr/local/bin/chromedriver

/usr/local/bin/chromedriver replace with actual path

PDHide
  • 18,113
  • 2
  • 31
  • 46
2

While using selenium's webdriver-manager, we had this same error from this line

driver = webdriver.Chrome(ChromeDriverManager().install())

To fix it, we opened a chrome window -> settings -> about chrome -> update chrome. Or chrome://settings/help on your browser.

After it finished building the new version of chrome, that same line no longer generates the error.

Of course, this only worked since Google had pushed a new version of chrome with a bugfix for whatever was causing that.

Joey Baruch
  • 4,180
  • 6
  • 34
  • 48
Shili Ho
  • 51
  • 5
1

chromedriver is being block; and to unblock enter:

xattr -d com.apple.quarantine /opt/homebrew/bin/chromedriver

'/opt/homebrew/bin/chromedriver' should be replaced by the path to the chromedriver in use on your machine.

To find the chromedriver being, enter:
which chromedriver

This resource may be helpful. It adds detail to PDHide's post.
Chromedriver can’t be opened because Apple cannot check it for malicious software

MikeySherm
  • 327
  • 4
  • 9