Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ jobs:
fail-fast: false
matrix:
os: [ "ubuntu-latest" ]
python-version: [ "3.9", "3.10", "3.11" ]
python-version: [ "3.10", "3.11", "3.12", "3.13" ]
runs-on: "${{ matrix.os }}"
defaults:
run:
Expand Down Expand Up @@ -87,7 +87,7 @@ jobs:
fail-fast: false
matrix:
os: [ "ubuntu-latest" ]
python-version: [ "3.9", "3.10", "3.11" ]
python-version: [ "3.10", "3.11", "3.12", "3.13" ]
runs-on: "${{ matrix.os }}"
steps:
- name: Check out repository
Expand All @@ -107,7 +107,7 @@ jobs:
- name: Setup PDM
uses: pdm-project/setup-pdm@v4
with:
python-version: "3.9"
python-version: "3.10"
pdm-dependency-install-flags: "not-used"
run-pdm-install: false
- name: Build package
Expand All @@ -125,7 +125,7 @@ jobs:
uses: actions/checkout@v4
- uses: ./.github/actions/setup
with:
python-version: "3.9"
python-version: "3.10"
pdm-dependency-install-flags: "-G dev"
- name: Check licences of dependencies
shell: bash
Expand Down
10 changes: 5 additions & 5 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ ci:
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: "v4.5.0"
rev: "v6.0.0"
hooks:
- id: check-added-large-files
- id: check-ast
Expand All @@ -33,13 +33,13 @@ repos:
language: fail
files: "\\.rej$"
- repo: https://github.com/charliermarsh/ruff-pre-commit
rev: "v0.1.8"
rev: "v0.14.9"
hooks:
- id: ruff
args: [ --fix, --exit-non-zero-on-fix ]
- id: ruff-check
args: [ --fix]
- id: ruff-format
- repo: https://github.com/pdm-project/pdm
rev: 2.17.0
rev: 2.26.1
hooks:
# Check that the lock file is up to date.
# We need the pdm lock file too
Expand Down
2 changes: 2 additions & 0 deletions changelog/75.breaking.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
Removed support for Python 3.9 which is now marked as End of Life.
The last openscm-units release to support Python 3.9 is v0.6.3.
1 change: 1 addition & 0 deletions changelog/75.docs.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Documented the strategy for the supported versions Python that openscm-units will support.
22 changes: 22 additions & 0 deletions docs/development.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ and [Semantic Versioning](https://semver.org/) to describe how the version
should change depending on the updates to the code base.

[](){releasing-reference}

## Releasing

Releasing is semi-automated via a CI job.
Expand Down Expand Up @@ -75,6 +76,27 @@ The steps required are the following:

1. Enjoy the newly available version

## Testing strategy

We support Python 3.10 and above.
We follow the [Python life-cycle schedule](https://devguide.python.org/versions/)
and will drop support for Python versions when they reach their end of life.
Given the nature of the package,
we want to ensure support for a broad range of Python versions to minimise any downstream constraints.
Libraries building on `openscm-units` are free to further restrict the Python versions
(or other dependencies) they support.

For downstream package maintainers we recommend following
the [SPEC 0000](https://scientific-python.org/specs/spec-0000/) deprecation policy.
This policy provides support for a key scientific packages for 24 months after release
and Python versions for 36 months after release.
The Python ecosystem is quicker to adopt new versions than it was previously
and these reduced support timelines reflect that.

None-the-less we also recommend that lockfiles are used for analysis projects
to capture the exact versions of dependencies used.
This will enable the project to be recreated in the future even if the Python version is no longer supported.

## Read the Docs

Our documentation is hosted by [Read the Docs (RtD)](https://www.readthedocs.org/),
Expand Down
2 changes: 1 addition & 1 deletion docs/gen_doc_stubs.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ def create_sub_packages_table(sub_packages: Iterable[PackageInfo]) -> str:
sub_packages_table_l.append(line)

if i == 0:
underline = f"| {'-'*sub_package_width} | {'-'*description_width} |"
underline = f"| {'-' * sub_package_width} | {'-' * description_width} |"
sub_packages_table_l.append(underline)

sub_packages_table = "\n".join(sub_packages_table_l)
Expand Down
2 changes: 1 addition & 1 deletion mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ plugins:
handlers:
python:
paths: [src]
import:
inventories:
# Cross-ref helpers (lots included here, remove what you don't want)
- https://www.attrs.org/en/stable/objects.inv
- https://unidata.github.io/cftime/objects.inv
Expand Down
Loading
Loading