Pythonのseleniumで動的サイトのスクレイピングをしようとしています。
OSError: [Errno 8] Exec format error: 'chromedriver'を解決できずに進めません。
環境: MacOS Sierra 10.12.6
発生している問題・エラーメッセージ
$ python3 /Users/local/Desktop/test.py Traceback (most recent call last): File "/Users/local/Desktop/test.py", line 4, in <module> driver = webdriver.Chrome() File "/usr/local/lib/python3.7/site-packages/selenium/webdriver/chrome/webdriver.py", line 73, in __init__ self.service.start() File "/usr/local/lib/python3.7/site-packages/selenium/webdriver/common/service.py", line 76, in start stdin=PIPE) File "/usr/local/Cellar/python/3.7.1/Frameworks/Python.framework/Versions/3.7/lib/python3.7/subprocess.py", line 769, in __init__ restore_signals, start_new_session) File "/usr/local/Cellar/python/3.7.1/Frameworks/Python.framework/Versions/3.7/lib/python3.7/subprocess.py", line 1516, in _execute_child raise child_exception_type(errno_num, err_msg, err_filename) OSError: [Errno 8] Exec format error: 'chromedriver'
該当のソースコード
test.py
11 from bs4 import BeautifulSoup 22 import requests 33 from selenium import webdriver 44 driver = webdriver.Chrome() 55 driver.get(以下略
あなたの回答
tips
プレビュー