Script to automatically install the ChromeDriver release compatible with the client's Chrome version.
Project description
chromedriver_autoinstall
Automatically downloads the version of ChromeDriver compatible with the client's version of Chrome (currently supports MacOS and Windows). Can be imported as a module and used to automatically reinstall ChromeDriver in its most updated/compatible version for any program that requires it.
Install:
Python 3.6 or higher is required
pip install chromedriver_autoinstall
Usage:
- To download chromedriver in the current directory, run
install_chromedriver
. - To use the autoinstaller as part of a program, write
import chromedriver_autoinstall
in your file. See the example below for this use case.
Quick Example:
from selenium import webdriver
import os
import chromedriver_autoinstall
import time
PATH = "./chromedriver"
URL = "https://github.com/RoastSea8/chromedriver-autoinstaller"
def main():
chromedriver_autoinstall.install()
# os.chmod('./chromedriver', 0o755) # MacOS only
driver = webdriver.Chrome(PATH)
driver.get(URL)
time.sleep(1000)
if __name__ == "__main__":
main()
Linux support coming soon.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for chromedriver_autoinstall-0.0.5.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 118356c89c31f7fc80b3d8f0926082b439ca22a7f723a800bd4b70c09ac22db8 |
|
MD5 | f050126184b0a7d6c451cd395cd1a685 |
|
BLAKE2b-256 | b0f6d5f714f113ebc120cc7732f4c169923f3517f29f1e1f9a9d03bc29d834ee |
Close
Hashes for chromedriver_autoinstall-0.0.5-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a87fce83c69ba0850dedb0254d91ba94b5a9bdbe3e2cef784eb051c34db29be7 |
|
MD5 | 63e13dd8d0ba2feeb66370515d27daf2 |
|
BLAKE2b-256 | fddf0ab2a3a7518ed8aef41ca75524d356de05b1cd06bfd95f420c7d1896e47a |