Skip to main content

Automatically fetches and downloads the appropriate Chrome version based on OS and architecture.

Project description

PyPI version License: MIT Downloads

ChromeFetcher

ChromeFetcher automates the process of fetching Chrome or ChromeDriver based on the operating system and architecture. It simplifies the task of downloading the appropriate version for your system.

Installation

To install ChromeFetcher, use pip:

pip install ChromeFetcher

Usage

Easily download ChromeDriver with:

from ChromeFetcher.chrome_fetcher import fetch_chrome

fetch_chrome(product='chromedriver')

Specify product as 'chrome' or 'chromedriver' to download. Options allow unzipping and cleanup post-download.

The fetch_chrome function offers a comprehensive approach to automatically downloading Chrome or ChromeDriver based on the user's operating system and architecture, streamlining the setup process for web automation tasks. Here's an overview of all the parameters available in this function:

  • channel (default='Stable'): This parameter allows users to specify the release channel of Chrome they wish to download. The default is set to 'Stable', but users can select other channels like 'Beta' or 'Dev' depending on their requirements.

  • product (default='chrome'): Determines whether to download Chrome or ChromeDriver. By setting this parameter to 'chrome', the function will download the browser. If set to 'chromedriver', it will fetch the driver needed for automation.

  • download_path (default=os.getcwd()): Specifies the directory where the downloaded file will be saved. By default, it uses the current working directory. Users can provide a custom path to suit their project structure.

  • unzip (default=True): A boolean parameter that, when set to True, automatically extracts the contents of the downloaded ZIP file. If False, the function leaves the ZIP file as is.

  • delete_zip (default=True): This parameter works in tandem with the unzip option. When set to True, it deletes the ZIP file after extraction to save space and keep the directory tidy. If unzip is False, this parameter has no effect.

Features

  • Automatically fetches Chrome or ChromeDriver.
  • Supports different OS and architectures.
  • Unzips and cleans up downloads optionally.

Contributing

Contributions, issues, and feature requests are welcome! Check our issues page.

License

Licensed under the MIT License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ChromeFetcher-0.0.9.tar.gz (4.4 kB view details)

Uploaded Source

Built Distribution

ChromeFetcher-0.0.9-py3-none-any.whl (5.0 kB view details)

Uploaded Python 3

File details

Details for the file ChromeFetcher-0.0.9.tar.gz.

File metadata

  • Download URL: ChromeFetcher-0.0.9.tar.gz
  • Upload date:
  • Size: 4.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.7

File hashes

Hashes for ChromeFetcher-0.0.9.tar.gz
Algorithm Hash digest
SHA256 1717216d813ae0796f8e1e26592bbe26d26b891af4979b992fe0b7a0dc48d283
MD5 d900c361466998234027c7b2ac3145c7
BLAKE2b-256 27afe63d70bbbb592132b7f2a6e0b10341b5557dfd2396f81e13e3ec464fffa6

See more details on using hashes here.

File details

Details for the file ChromeFetcher-0.0.9-py3-none-any.whl.

File metadata

File hashes

Hashes for ChromeFetcher-0.0.9-py3-none-any.whl
Algorithm Hash digest
SHA256 fd9d916041b1cae7b0e02d0d44306e53d088c302e0482295d8b71afd65c2f735
MD5 76e7399ce55dedabfaa20af44196f234
BLAKE2b-256 7b11ed285160848b122c1f9aa7ab708c58d15d29bb664beba1033d3d4977b1a3

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page