Skip to content

Commit b895831

Browse files
committed
Merge branch 'python-version-increment-3.12'
2 parents 5bfa0c0 + 6dda5a6 commit b895831

File tree

8 files changed

+78
-41
lines changed

8 files changed

+78
-41
lines changed
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
# .github/workflows/github-pages-docs-publish.yml
2+
# This workflow will build the Documentation site and publish it to GitHub Pages
3+
4+
name: github-pages-docs-publish
5+
on:
6+
push:
7+
branches:
8+
- main
9+
permissions:
10+
contents: write
11+
jobs:
12+
deploy:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v4
16+
- name: Configure Git Credentials
17+
run: |
18+
git config user.name github-actions[bot]
19+
git config user.email 41898282+github-actions[bot]@users.noreply.github.com
20+
- uses: actions/setup-python@v5
21+
with:
22+
python-version: 3.x
23+
- run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV
24+
- uses: actions/cache@v4
25+
with:
26+
key: mkdocs-material-${{ env.cache_id }}
27+
path: ~/.cache
28+
restore-keys: |
29+
mkdocs-material-
30+
- run: pip install mkdocs-material
31+
- run: mkdocs gh-deploy --force

.github/workflows/pypi-publish.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,16 +13,16 @@ jobs:
1313
name: Build the distribution
1414
runs-on: ubuntu-latest
1515
steps:
16-
- uses: actions/checkout@v3
17-
- uses: actions/setup-python@v3
16+
- uses: actions/checkout@v4 # latest as at Feb 2024
17+
- uses: actions/setup-python@v5 # latest as at Feb 2024
1818
with:
1919
python-version: 3.11
2020

2121
- run: |
2222
pip install poetry
2323
poetry build
2424
25-
- uses: actions/upload-artifact@v3
25+
- uses: actions/upload-artifact@v4 # latest as at Feb 2024
2626
with:
2727
path: ./dist
2828

@@ -38,9 +38,9 @@ jobs:
3838
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing
3939
steps:
4040
- name: Download package distributions from build job
41-
uses: actions/download-artifact@v3
41+
uses: actions/download-artifact@v4 # latest as at Feb 2024
4242

4343
- name: Publish package distributions to PyPI
44-
uses: pypa/gh-action-pypi-publish@release/v1
44+
uses: pypa/gh-action-pypi-publish@release/v1 # latest as at Feb 2024
4545
with:
4646
packages-dir: artifact

.github/workflows/test-all-branches.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,12 @@ jobs:
1515
runs-on: ubuntu-latest
1616
strategy:
1717
matrix:
18-
python-version: ["3.7", "3.8", "3.9", "3.10", "3.11"]
18+
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
1919

2020
steps:
21-
- uses: actions/checkout@v3
21+
- uses: actions/checkout@v4 # latest as at Feb 2024
2222
- name: Set up Python ${{ matrix.python-version }}
23-
uses: actions/setup-python@v4
23+
uses: actions/setup-python@v5 # latest as at Feb 2024
2424
with:
2525
python-version: ${{ matrix.python-version }}
2626
- name: Install dependencies

.github/workflows/testpypi-publish.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,16 +13,16 @@ jobs:
1313
name: Build the distribution
1414
runs-on: ubuntu-latest
1515
steps:
16-
- uses: actions/checkout@v3
17-
- uses: actions/setup-python@v3
16+
- uses: actions/checkout@v4 # latest as at Feb 2024
17+
- uses: actions/setup-python@v5 # latest as at Feb 2024
1818
with:
1919
python-version: 3.11
2020

2121
- run: |
2222
pip install poetry
2323
poetry build
2424
25-
- uses: actions/upload-artifact@v3
25+
- uses: actions/upload-artifact@v4 # latest as at Feb 2024
2626
with:
2727
path: ./dist
2828

@@ -38,10 +38,10 @@ jobs:
3838
id-token: write # IMPORTANT: this permission is mandatory for trusted publishing
3939
steps:
4040
- name: Download package distributions from build job
41-
uses: actions/download-artifact@v3
41+
uses: actions/download-artifact@v4 # latest as at Feb 2024
4242

4343
- name: Publish package distributions to PyPI
44-
uses: pypa/gh-action-pypi-publish@release/v1
44+
uses: pypa/gh-action-pypi-publish@release/v1 # latest as at Feb 2024
4545
with:
4646
repository_url: https://test.pypi.org/legacy/
4747
packages-dir: artifact
Binary file not shown.

docs/changelog.md

Lines changed: 20 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,15 @@ title: Changelog
33
authors: Dr Marcus Baw
44
---
55

6+
## 1.3.5
7+
8+
- Adds Python 3.12 to the supported versions which are tested in the GitHub Action CI/CD pipeline.
9+
- Removes Python 3.7 from the supported versions which are tested in the GitHub Action CI/CD pipeline.
10+
- Adds a source document regarding the NHS number specification to the docs/_source-documents folder.
11+
- Upgrades all GitHub Actions within workflows (eg `actions/checkout@v3`) to latest version of the Node 20-based actions
12+
613
## 1.3.4
14+
715
- Revert of the new logo, minor edits to the documentation, accepted Anchit PR
816
- Reverted to plain code rather than Carbon for the code snippets.
917
- No changes to Python code
@@ -14,28 +22,27 @@ authors: Dr Marcus Baw
1422

1523
## 1.3.2
1624

17-
* GitHub action for CI/CD to publish to live PyPi
18-
* Minor documentation updates
25+
- GitHub action for CI/CD to publish to live PyPi
26+
- Minor documentation updates
1927

2028
## 1.3.1
2129

22-
* Changed to Netlify for documentation site deployment
23-
* GitHub action for CI/CD to publish to Test PyPi
30+
- Changed to Netlify for documentation site deployment
31+
- GitHub action for CI/CD to publish to Test PyPi
2432

2533
## 1.3.0 (Refactor, June 2023)
2634

27-
* GitHub repo is transferred from Andy Law to the Faculty of Clinical Informatics.
28-
* Extensive refactor to add new features such as generation of NHS numbers.
29-
* Adds documentation site published to GitHub Pages with GitHub Actions publication.
30-
* Adds GitHub Actions for CI/CD to publish to PyPI.
31-
* Python version support added for 3.11
32-
* Python version support dropped for 3.5, Python 2, etc
33-
35+
- GitHub repo is transferred from Andy Law to the Faculty of Clinical Informatics.
36+
- Extensive refactor to add new features such as generation of NHS numbers.
37+
- Adds documentation site published to GitHub Pages with GitHub Actions publication.
38+
- Adds GitHub Actions for CI/CD to publish to PyPI.
39+
- Python version support added for 3.11
40+
- Python version support dropped for 3.5, Python 2, etc
3441

3542
## 1.2.2
3643

37-
* Adds support for additional Python versions (3.8, 3.9, 3.10).
44+
- Adds support for additional Python versions (3.8, 3.9, 3.10).
3845

3946
## 1.2.1
4047

41-
* Original package is known as `nhs-number` on PyPI and [NhsNumberChecks](https://github.com/andylaw/NhsNumberChecks) on GitHub.
48+
- Original package is known as `nhs-number` on PyPI and [NhsNumberChecks](https://github.com/andylaw/NhsNumberChecks) on GitHub.

mkdocs.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,20 +4,20 @@ site_name: nhs-number
44
repo_url: https://github.com/uk-fci/nhs-number
55
repo_name: uk-fci/nhs-number
66

7-
copyright: Copyright © 2021-2023 Andy Law, The University of Edinburgh, and the Faculty of Clinical Informatics
7+
copyright: Copyright © 2021-2025 Andy Law, The University of Edinburgh, Marcus Baw, and the Faculty of Clinical Informatics (now defunct)
88

99
# explicitly defines the Nav so we can set order of pages other than default alphabetical
1010
nav:
1111
- Introduction:
12-
- "index.md"
13-
- About NHS Numbers: "nhs-numbers.md"
12+
- "index.md"
13+
- About NHS Numbers: "nhs-numbers.md"
1414
- Getting Started:
15-
- Installation: "installation.md"
16-
- Usage: "usage.md"
15+
- Installation: "installation.md"
16+
- Usage: "usage.md"
1717
- Developer Guide:
18-
- Project Structure: "developing.md"
19-
- Documentation: 'documentation.md'
20-
- Useful URLs: "useful_urls.md"
18+
- Project Structure: "developing.md"
19+
- Documentation: "documentation.md"
20+
- Useful URLs: "useful_urls.md"
2121
- Contributors: "contributors.md"
2222
- Changelog: "changelog.md"
2323

@@ -35,7 +35,7 @@ theme:
3535
icon:
3636
logo: material/check-all
3737
favicon: _assets/_images/done_all.svg
38-
custom_dir: 'overrides'
38+
custom_dir: "overrides"
3939
features:
4040
- content.action.edit # explicitly adds edit button (Material4MkDocs9.0)
4141
- content.action.view # explicitly adds view button (Material4MkDocs9.0)

pyproject.toml

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
[tool.poetry]
22
name = "nhs-number"
3-
version = "1.3.4"
3+
version = "1.3.5"
44
description = "Python package to provide utilities for NHS Numbers, including validity checks, normalisation, and generation."
55
authors = [
66
"Andy Law <[email protected]>",
7-
"Marcus Baw <marcusbaw@gmail.com>",
7+
"Marcus Baw <marcus@marcusbaw.com>",
88
]
99
license = "MIT"
1010
readme = "README.md"
@@ -24,22 +24,21 @@ classifiers = [
2424
'Intended Audience :: Healthcare Industry',
2525
'Intended Audience :: Science/Research',
2626
'Topic :: Scientific/Engineering :: Medical Science Apps.',
27-
'Programming Language :: Python :: 3.7',
2827
'Programming Language :: Python :: 3.8',
2928
'Programming Language :: Python :: 3.9',
3029
'Programming Language :: Python :: 3.10',
3130
'Programming Language :: Python :: 3.11',
31+
'Programming Language :: Python :: 3.12',
3232
]
3333

3434
[tool.poetry.dependencies]
35-
python = "^3.7"
35+
python = "^3.8"
3636

3737
[tool.poetry.dev-dependencies]
38-
pytest = "^7.3.1"
38+
pytest = "^8.0.0"
3939
black = "^23.3.0"
4040
mkdocs-material = "^9.1.15"
4141

42-
4342
[tool.poetry.urls]
4443
"Issue Tracker" = "https://github.com/uk-fci/nhs-number/issues"
4544

0 commit comments

Comments
 (0)