https://www.cnblogs.com/somenothing/p/14356004.html
pip install selenium
或
pip3 install selenium
直接把chromedriver移动到 /usr/bin
sudo mv chromedriver /usr/bin
chrome_options = Options() chrome_options.add_argument("--headless") chrome_options.add_argument(‘--disable-gpu‘) chrome_options.add_argument(‘--no-sandbox‘)
browser=webdriver.Chrome(executable_path="/usr/bin/chromedriver", chrome_options=chrome_options)
原文:https://www.cnblogs.com/somenothing/p/14356017.html