Skip to main content

Installs the latest Chrome/Firefox/Opera/PhantomJS/Edge web drivers automatically.

Project description

Pyderman (Selenium Web Driver Installer)

Ubuntu MacOS Windows MacOS (SUR)

This is a fast, simple, dependency-free package that can automatically find & download any version of the Google Chrome (chromeDriver), Firefox (geckoDriver), PhantomJS, Opera (operaDriver), and Edge (edgeDriver) web drivers.

This project was built to allow developers to seamlessly include selenium support on the user-side, without requiring any manual configuration on their part. It will automatically locate the correct driver binary for the platform & version you choose, as well as setting the os-specific permissions after downloading.

It is tested daily on Windows/Linux/macOS against Python versions 3.7+.

Installation

To install the library, run:

pip install pyderman

Usage

After installed, call it in your code like so:

import pyderman as driver
path = driver.install(browser=driver.firefox)
print('Installed geckodriver driver to path: %s' % path)

There are options for the output directory, disabling printout, running chmod on the downloaded executable, automatic overwriting, executable file name, and version number. All parameters are optional, and the default values are listed below.

This example downloads the Chrome Driver instead, by changing browser like so:

import pyderman as dr
path = dr.install(browser=dr.chrome, file_directory='./lib/', verbose=True, chmod=True, overwrite=False, version=None, filename=None, return_info=False)
print('Installed chromedriver to path: %s' % path)

The download is very fast, and will skip downloading if the file already exists. This behavior can be toggled with overwrite.

Notes

Note on MS Edge

Microsoft has switched Edge to use a flavor of Chrome behind the scenes. As of October 2019, Pyderman will download this MS Chromium Driver. Their driver is experimental, so make sure you know what you're doing if you use this driver. If you require stability, it is recommended you specify a version instead of using the "latest".

Note on macOS

Some versions of macOS have certificate issues with Python. Typically, in recent versions of Python, it will prompt you to install these when you install Python. Since Python needs these installed in order to make https requests, you may need to install these first. Depending on your project, it may also be possible to include a library to automatically import these certificates. Please visit this link to learn more.

Note on Big Sur

Apple broke a ton of compatibility moving to Big Sur, and now many of the web drivers do not have working builds within the new architecture. This project will only halfheartedly attempt to keep any drivers working on Big Sur architecture until all the available drivers have stable release patterns for the platform.

Why's it called 'Pyderman'?

Because it installs web-drivers. Get it?

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

pyderman-3.2.1.tar.gz (11.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyderman-3.2.1-py3-none-any.whl (13.1 kB view details)

Uploaded Python 3

File details

Details for the file pyderman-3.2.1.tar.gz.

File metadata

  • Download URL: pyderman-3.2.1.tar.gz
  • Upload date:
  • Size: 11.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.9.12

File hashes

Hashes for pyderman-3.2.1.tar.gz
Algorithm Hash digest
SHA256 6bd7e10242b73f9802d3bda06f03cb4811ec564a32afa6b45adcc93b36b5ec53
MD5 9bdd61e5d1b2ae2ca46205ea93f1ff42
BLAKE2b-256 f89642e49adeb19092b523ee5ad13cf7bfaa582a36417ef21180e020e839f7c4

See more details on using hashes here.

File details

Details for the file pyderman-3.2.1-py3-none-any.whl.

File metadata

  • Download URL: pyderman-3.2.1-py3-none-any.whl
  • Upload date:
  • Size: 13.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.9.12

File hashes

Hashes for pyderman-3.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 fd6448aa3d5e2b88dd174c9304053b3d3a6c4f2b80875acc2808e57afe44322b
MD5 4649341a835d1c33d351188b9787b782
BLAKE2b-256 ecc664bafa32a5c9c0a7c0449c726b803da341ed156dbd44941a889de3bff474

See more details on using hashes here.

Supported by

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