selenium-examples-using-python

Selenium browser automation examples using Python programming

https://github.com/gig-cymru-nhs-wales/selenium-examples-using-python

Science Score: 44.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (11.4%) to scientific vocabulary
Last synced: 6 months ago · JSON representation ·

Repository

Selenium browser automation examples using Python programming

Basic Info
  • Host: GitHub
  • Owner: GIG-Cymru-NHS-Wales
  • Language: Python
  • Default Branch: main
  • Size: 10.7 KB
Statistics
  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • Open Issues: 0
  • Releases: 0
Created 10 months ago · Last pushed 9 months ago
Metadata Files
Readme Citation

README.md

Selenium examples using Python

Demonstration of:

  • Selenium browser automation testing
  • Python programming language
  • ChromeDriver extends Webdriver by adding Chromium-specific capabilities

Many more examples are here:

Install

Install Python

Install Python from https://www.python.org/

Run this to confirm your version:

sh python -v

Output should be at least:

stdout Python 3.13.1

Install uv

Install uv from https://github.com/astral-sh/uv

Run this to confirm your version:

sh uv version

Output should be at least:

stdout uv 0.6.14

Install Selenium

Install Selenium WebDriver:

sh uv add selenium

Update

Run:

sh uv self update uv lock --upgrade uv sync

Run

Run:

sh uv run main.py

The script will do three things:

  1. Launch your local Chrome web browser to view the free open source testing examples web page https://testingexamples.github.io.

  2. Interact with the web page in various ways, such as finding elements, clicking on elements, filling in form inputs, etc.

  3. Print some typical HTML tag output that demonstrates the program is running successfully.

Troubleshooting “chromedriver” Not Opened

If you get this kind of error message:

txt “chromedriver” Not Opened. Apple could not verify “chromedriver” is free of malware that may harm your Mac or compromise your privacy.

Or this kind of error message:

txt Apple is not able to verify that it is free from malware that could harm your Mac or compromise your privacy. Don’t open this unless you are certain it is from a trustworthy source.

Then click "Done".

Try this command line solution:

sh xattr -d com.apple.quarantine $(which chromedriver) 2>/dev/null

Try adjusting your system settings:

  • Apple menu -> Settings -> Security & Privacy -> General

  • See the entry that says: "chromedriver" was blocked to protect your Mac.

  • Click the button "Allow Anyway".

Troubleshooting "This version of ChromeDriver …"

If you get this kind of error message:

txt UnhandledPromiseRejectionWarning: SessionNotCreatedError: session not created: This version of ChromeDriver only supports Chrome version …

Then you may need to harmonize your Chrome browser app and your Chrome webdriver.

If you use macOS brew, then upgrade chromedriver:

sh brew upgrade chromedriver

To update your Chrome browser app:

  • On your computer, open Chrome.

  • Find your current Chrome version by typing in the URL bar: chrome://version/.

  • You should see a web page with many details, and you should see the first line with the version number, such as: "Google Chrome 135.0.7049.86 (Official Build)".

  • At top right, tap the "More" icon, which is 3 vertical dots.

  • You see the "More" menu. If you see a menu item "Update", then choose it. If you don't see a menu item "Update", then you're on the current version.

To update your Chrome webdriver:

  • Go to https://chromedriver.chromium.org/downloads

  • Download the version that matches your Chrome browser app.

Tracking

  • Package: selenium-examples-using-python
  • Version: 1.4.0
  • Created: 2019-11-02T00:00:00Z
  • Updated: 2025-04-24T13:58:02Z
  • License: GPL-2.0-or-greater or for custom license contact us
  • Contact: Joel Parker Henderson (joel.henderson@wales.nhs.uk)

Owner

  • Name: GIG Cymru - NHS Wales
  • Login: GIG-Cymru-NHS-Wales
  • Kind: organization

Citation (CITATION.cff)

cff-version: 1.2.0
title: Selenium examples using Python
message: >-
  If you use this work and you want to cite it,
  then you can use the metadata from this file.
type: software
authors:
  - given-names: Joel Parker
    family-names: Henderson
    email: joel.henderson@wales.nhs.uk
    affiliation: wales.nhs.uk
    orcid: 'https://orcid.org/0009-0000-4681-282X'
identifiers:
  - type: url
    value: 'https://github.com/gig-cymru-nhs-wales/selenium-examples-using-python/'
    description: Selenium examples using Python
repository-code: 'https://github.com/gig-cymru-nhs-wales/selenium-examples-using-python/'
abstract: >-
  Selenium examples using Python
license: See license file

GitHub Events

Total
  • Watch event: 1
  • Push event: 3
  • Create event: 1
Last Year
  • Watch event: 1
  • Push event: 3
  • Create event: 1

Dependencies

pyproject.toml pypi
  • selenium >=4.31.0
uv.lock pypi
  • attrs 25.3.0
  • certifi 2025.1.31
  • cffi 1.17.1
  • h11 0.16.0
  • idna 3.10
  • outcome 1.3.0.post0
  • pycparser 2.22
  • pysocks 1.7.1
  • selenium 4.31.0
  • selenium-examples-using-python 0.1.0
  • sniffio 1.3.1
  • sortedcontainers 2.4.0
  • trio 0.30.0
  • trio-websocket 0.12.2
  • typing-extensions 4.13.2
  • urllib3 2.4.0
  • websocket-client 1.8.0
  • wsproto 1.2.0