Skip to content

Instantly share code, notes, and snippets.

@germainlefebvre4
Last active September 29, 2018 14:53
Show Gist options
  • Save germainlefebvre4/8737e1eaa3f39fa0b33793682b8f327e to your computer and use it in GitHub Desktop.
Save germainlefebvre4/8737e1eaa3f39fa0b33793682b8f327e to your computer and use it in GitHub Desktop.
Selenium Python - First-Step : Very simple example
#!/usr/bin/python2
from selenium import webdriver
chrome_options = webdriver.ChromeOptions()
chrome_options.add_argument('--headless')
chrome_options.add_argument('--no-sandbox')
driver = webdriver.Chrome('chromedriver', chrome_options=chrome_options, service_args=['--verbose', '--log-path=/tmp/chromedriver.log'])
driver.get('https://python.org')
print driver.title
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment