Derives significant dates for UK elections
Project description
uk-election-timetables
This library encapsulates timetable legislation for elections run in the United Kingdom and its devolved administrations.
The election timetable varies based on:
- Type of Post - Parliamentary, Local, devolved Government, etc.
- Country - The United Kingdom has up to four different rules for the same type of election, one for each country.
- Calendar - each country has their own unique set of Bank Holidays.
Usage (publishing of candidate lists)
from datetime import date
from uk_election_timetables.elections.uk_parliament import UKParliamentElection
election = UKParliamentElection(date(2019, 2, 21))
print(election.sopn_publish_date) # date(2019, 1, 25)
Updating Bank Holiday Dates
This project checks daily for additions to the government bank holiday dataset at https://www.gov.uk/bank-holidays.json. When an addition is identified in the .gov file, this project will automatically create a GitHub issue to update our local bank holiday dataset.
To update bank-holidays.json
with additions from the government supplied file, run the following within your venv:
python manage_bank_holidays.py --update
Documentation
Hosted by readthedocs at https://uk-election-timetables.readthedocs.io/
Installation
pip install uk_election_timetables
Test
pytest
Supported Election Types
- Local
- City of London Local
- United Kingdom Parliament
- Scottish Parliament
- Senedd Cymru
- Northern Ireland Assembly
- Mayoral
- Mayoral (London)
- Greater London Assembly
- Police and Crime commissioner
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
File details
Details for the file uk_election_timetables-4.1.0.tar.gz
.
File metadata
- Download URL: uk_election_timetables-4.1.0.tar.gz
- Upload date:
- Size: 17.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0b225e786085bdc9e40fd59619b2134c0bb316e2cfcf89c8ee894b8dcbf52719 |
|
MD5 | 8f121666a9faf919afdd82081a823e23 |
|
BLAKE2b-256 | 92249e6103ddb38856ff83906205f2b16036ef2d99f2c3fc7089164e8bb8bf47 |
Provenance
The following attestation bundles were made for uk_election_timetables-4.1.0.tar.gz
:
Publisher:
python-publish.yml
on DemocracyClub/uk-election-timetables
-
Statement type:
https://in-toto.io/Statement/v1
- Predicate type:
https://docs.pypi.org/attestations/publish/v1
- Subject name:
uk_election_timetables-4.1.0.tar.gz
- Subject digest:
0b225e786085bdc9e40fd59619b2134c0bb316e2cfcf89c8ee894b8dcbf52719
- Sigstore transparency entry: 148386045
- Sigstore integration time:
- Predicate type:
File details
Details for the file uk_election_timetables-4.1.0-py3-none-any.whl
.
File metadata
- Download URL: uk_election_timetables-4.1.0-py3-none-any.whl
- Upload date:
- Size: 20.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/5.1.1 CPython/3.12.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 65d74ba008f2e89a6f7c5a84d3fea96664104390e545193c116f78b56aa8a333 |
|
MD5 | 1ecae646f0aa2a705d91575b3f6f6fc5 |
|
BLAKE2b-256 | c6607070f929b7f29f899fb964398158f7f837cf3327c2f15196ec7d79862cc3 |
Provenance
The following attestation bundles were made for uk_election_timetables-4.1.0-py3-none-any.whl
:
Publisher:
python-publish.yml
on DemocracyClub/uk-election-timetables
-
Statement type:
https://in-toto.io/Statement/v1
- Predicate type:
https://docs.pypi.org/attestations/publish/v1
- Subject name:
uk_election_timetables-4.1.0-py3-none-any.whl
- Subject digest:
65d74ba008f2e89a6f7c5a84d3fea96664104390e545193c116f78b56aa8a333
- Sigstore transparency entry: 148386048
- Sigstore integration time:
- Predicate type: