This folder holds scripts and other info used for the governing board election.
Scripts in this folder are used to (approximately) find emails of users that meet the eligibility requirements so that links to active elections can be sent to them.
There are two scripts, which look at two different sources to find emails:
- github_emails.py extracts emails from GitHub activity
- cncf_emails.py uses a CNCF list of emails
Both take a .csv
file of users from devstats as input.
Reconciling the lists and tracking down missing users from this point is manual.
- Find eligible github users using this link
- Export the data as a
.csv
(from the Table title, go to Inspect->Data->Download CSV)
To run this script you will need a GitHub OAuth token to make requests to GitHub (it does not require any specific access).
This script will create a file called emails.csv
which contains the found emails.
python3 github_emails.py --file users.csv --token $GITHUB_OAUTH_TOKEN
This script will create a file called found_emails.csv
with the found emails and one called missing_emails.csv
with the usernames it couldn't map.
# you will need to install the pandas library
python3 -m venv ./voters
source ./voters/bin/activate
pip3 install pandas
# run the script
python3 cncf_emails.py --file users.csv