Python bindings for the Durham University (UK) Directory
This package provides basic python bindings for the Durham University Directory, where Durham University students and staff can look up fellow students and staff.
It is nothing more than a wrapper around requests and bs4, and absolutely
nothing clever is being done (although I do think the code is pleasantly
simple).
Installation
python -m pip install durham-directory
CLI Usage
durham-directory --help
durham-directory --oname John --surname Morris
API Usage
from durham_directory import Query
query = Query(username="me") # will prompt for password when evaluated
query(oname="John", surname="Morris", type_="any")
Or if you want to choose one result:
from durham_directory import QueryOne
query = QueryOne()
query(oname="John", surname="Morris", type_="any")
We use fuzzy string matching via fuzzywuzzy (ignoring the title) to sort
results, as Durham appears to return them bogosorted.
Scripts
An example script parsing a csv extracted from the spreadsheets it seems
timetabling send around and printing Org-mode tables is in parse_csv.py.
Metadata
Release files for durham-directory 1.3.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| durham-directory-1.3.0.tar.gz | 4.2 kB | Without provenance | Details for durham-directory-1.3.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| durham_directory-1.3.0-py3-none-any.whl | Python 3 | none | any | Details for durham_directory-1.3.0-py3-none-any.whl |
Total release size: 8.7 kB
Release files / durham-directory-1.3.0.tar.gz
| Download URL | durham-directory-1.3.0.tar.gz |
|---|---|
| Size | 4.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ceadf7de419ee4e7f425247e1b1585e7e3c97b8ac0eba70d09ed2268b021ae93
|
|
BLAKE2b-256 checksum How to use checksums |
96fc2891ed762f41769dc83a2743639f7296bec3184084d81d45e24b7c9e92dd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.1.10 CPython/3.9.9 Linux/5.14.16-arch1-1
|
Release files / durham_directory-1.3.0-py3-none-any.whl
| Download URL | durham_directory-1.3.0-py3-none-any.whl |
|---|---|
| Size | 4.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
0ab5bba4d6a4daa4940cb7d928d3e0ee27f8930f19052da8e56b397bcd9d6771
|
|
BLAKE2b-256 checksum How to use checksums |
e02f2f6272366825d293b54cd53aca60508279c69a1e4cd39b3ddece1b6b6a34
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.1.10 CPython/3.9.9 Linux/5.14.16-arch1-1
|
Security for durham-directory 1.3.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.