Skip to content

Commit ba83a67

Browse files
authored
Add support for Python 3.12 (#104)
- inboard will now run tests with Python 3.12, in addition to 3.8-3.11 - inboard will now build and publish its PyPI package using Python 3.12 - inboard will now include a Python 3.12 classifier in its PyPI package - inboard will now ship Docker images running Python 3.12, in addition to 3.8-3.11, and Docker images tagged with `latest` will now use 3.12
1 parent 145313e commit ba83a67

File tree

5 files changed

+14
-13
lines changed

5 files changed

+14
-13
lines changed

.github/workflows/ci.yml

+5-5
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ jobs:
5454
id-token: write
5555
strategy:
5656
matrix:
57-
python-version: ["3.8", "3.9", "3.10", "3.11"]
57+
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
5858
steps:
5959
- uses: actions/checkout@v4
6060
- uses: actions/setup-python@v5
@@ -93,7 +93,7 @@ jobs:
9393
*) echo "Incorrect Hatch virtualenv." && exit 1 ;;
9494
esac
9595
- name: Test that Git tag version and Python package version match
96-
if: github.ref_type == 'tag' && matrix.python-version == '3.11'
96+
if: github.ref_type == 'tag' && matrix.python-version == '3.12'
9797
run: |
9898
GIT_TAG_VERSION=$GITHUB_REF_NAME
9999
PACKAGE_VERSION=$(hatch version)
@@ -115,7 +115,7 @@ jobs:
115115
- name: Publish Python package to PyPI
116116
if: >
117117
github.ref_type == 'tag' &&
118-
matrix.python-version == '3.11' &&
118+
matrix.python-version == '3.12' &&
119119
needs.setup.outputs.environment-name == 'PyPI'
120120
uses: pypa/gh-action-pypi-publish@release/v1.8
121121
docker:
@@ -125,7 +125,7 @@ jobs:
125125
fail-fast: false
126126
matrix:
127127
linux-version: ["", "alpine", "slim"]
128-
python-version: ["3.8", "3.9", "3.10", "3.11"]
128+
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
129129
steps:
130130
- uses: actions/checkout@v4
131131
- uses: actions/setup-python@v5
@@ -269,7 +269,7 @@ jobs:
269269
-u ${{ github.actor }} --password-stdin
270270
- name: Tag and push Docker images with latest tags
271271
if: >
272-
matrix.python-version == '3.11' &&
272+
matrix.python-version == '3.12' &&
273273
(
274274
github.ref_type == 'tag' ||
275275
github.ref == 'refs/heads/develop' ||

.github/workflows/codeql.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ jobs:
2020
- uses: actions/checkout@v4
2121
- uses: actions/setup-python@v5
2222
with:
23-
python-version: "3.11"
23+
python-version: "3.12"
2424
- uses: github/codeql-action/init@v3
2525
with:
2626
languages: python

Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# syntax=docker/dockerfile:1
2-
ARG PYTHON_VERSION=3.11 LINUX_VERSION=
2+
ARG PYTHON_VERSION=3.12 LINUX_VERSION=
33
FROM python:${PYTHON_VERSION}${LINUX_VERSION:+-$LINUX_VERSION} AS builder
44
LABEL org.opencontainers.image.authors="Brendon Smith <bws@bws.bio>"
55
LABEL org.opencontainers.image.description="Docker images and utilities to power your Python APIs and help you ship faster."

docs/docker.md

+6-6
Original file line numberDiff line numberDiff line change
@@ -20,24 +20,24 @@ Please see [inboard Git tags](https://github.com/br3ndonland/inboard/tags), [inb
2020
docker pull ghcr.io/br3ndonland/inboard:starlette
2121

2222
# Pull image from specific release
23-
docker pull ghcr.io/br3ndonland/inboard:0.38.0-fastapi
23+
docker pull ghcr.io/br3ndonland/inboard:0.67.0-fastapi
2424

2525
# Pull image from latest minor version release (new in inboard 0.22.0)
26-
docker pull ghcr.io/br3ndonland/inboard:0.38-fastapi
26+
docker pull ghcr.io/br3ndonland/inboard:0.67-fastapi
2727

2828
# Pull image with specific Python version
29-
docker pull ghcr.io/br3ndonland/inboard:fastapi-python3.11
29+
docker pull ghcr.io/br3ndonland/inboard:fastapi-python3.12
3030

3131
# Pull image from latest minor release and with specific Python version
32-
docker pull ghcr.io/br3ndonland/inboard:0.38-fastapi-python3.11
32+
docker pull ghcr.io/br3ndonland/inboard:0.67-fastapi-python3.12
3333

3434
# Append `-alpine` to image tags for Alpine Linux (new in inboard 0.11.0)
3535
docker pull ghcr.io/br3ndonland/inboard:latest-alpine
36-
docker pull ghcr.io/br3ndonland/inboard:0.38-fastapi-alpine
36+
docker pull ghcr.io/br3ndonland/inboard:0.67-fastapi-alpine
3737

3838
# Append `-slim` to any of the above for Debian slim (new in inboard 0.11.0)
3939
docker pull ghcr.io/br3ndonland/inboard:latest-slim
40-
docker pull ghcr.io/br3ndonland/inboard:0.38-fastapi-slim
40+
docker pull ghcr.io/br3ndonland/inboard:0.67-fastapi-slim
4141
```
4242

4343
## Use images in a _Dockerfile_

pyproject.toml

+1
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ classifiers = [
1212
"Programming Language :: Python :: 3.9",
1313
"Programming Language :: Python :: 3.10",
1414
"Programming Language :: Python :: 3.11",
15+
"Programming Language :: Python :: 3.12",
1516
"Topic :: Internet :: Log Analysis",
1617
"Topic :: Internet :: WWW/HTTP :: HTTP Servers",
1718
"Topic :: Internet :: WWW/HTTP :: WSGI",

0 commit comments

Comments
 (0)