geckodriver-autoinstaller
geckodriver-autoinstaller is a Python library designed to automatically download and install the correct version of geckodriver that supports the currently installed version of Mozilla Firefox. It aims to simplify the setup process for Selenium users who need to automate Firefox. The latest version is 0.1.0, released in February 2020, and the project appears to be unmaintained.
Warnings
- deprecated This library (geckodriver-autoinstaller) has not been updated since February 2020 (version 0.1.0). A popular fork, `pyautogecko`, explicitly states that this project is 'no longer maintained'. It may not be compatible with recent versions of Firefox or Selenium, and critical bug fixes or security updates are unlikely.
- gotcha `geckodriver` is exclusively for Mozilla Firefox. This library will only manage the driver for Firefox and cannot be used for Chrome, Edge, or other browsers. The project description in some contexts might have mistakenly referred to Chrome, but the official PyPI and GitHub state Firefox.
- gotcha Due to its unmaintained status, this library's installed `geckodriver` version might become incompatible with newer Firefox browser releases or recent Selenium versions. This can lead to `SessionNotCreatedException` or similar runtime errors.
- gotcha Even with automatic installation, the `geckodriver` executable might not be correctly found in the system's PATH, or there could be permission denied errors, especially in Linux/macOS or CI/CD environments.
Install
-
pip install geckodriver-autoinstaller
Imports
- geckodriver_autoinstaller
import geckodriver_autoinstaller
Quickstart
import geckodriver_autoinstaller
from selenium import webdriver
# Automatically install geckodriver
geckodriver_autoinstaller.install()
# Initialize Firefox WebDriver
driver = webdriver.Firefox()
# Example usage
driver.get("https://www.google.com")
print(f"Page title: {driver.title}")
driver.quit()