diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8c2e8339..3941d138 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -31,7 +31,7 @@ jobs: steps: - uses: actions/checkout@v3 - - uses: hynek/build-and-inspect-python-package@f336040a31ea03a2551adcc994d3ddb2f3ea3f7f + - uses: hynek/build-and-inspect-python-package@6a687a6d3567bc184c1fc694ee7f0f328594ef25 - name: Set up ${{ matrix.python.name }} uses: actions/setup-python@v4 @@ -59,6 +59,7 @@ jobs: strategy: fail-fast: false matrix: + # Keep list in-sync with noxfile/tests & pyproject.toml. python: - name: CPython 3.8 action: 3.8 @@ -68,6 +69,8 @@ jobs: action: '3.10' - name: CPython 3.11 action: '3.11' + - name: CPython 3.12 + action: '3.12' - name: PyPy 3.8 action: pypy3.8 task: @@ -87,6 +90,8 @@ jobs: uses: actions/setup-python@v4 with: python-version: ${{ matrix.python.action }} + allow-prereleases: true + cache: pip - name: Install dependencies run: python -m pip install --upgrade pip nox @@ -252,7 +257,7 @@ jobs: python -Im coverage html --skip-covered --skip-empty # Report and write to summary. - python -Im coverage report | sed 's/^/ /' >> $GITHUB_STEP_SUMMARY + python -Im coverage report --format=markdown >> $GITHUB_STEP_SUMMARY # Report again and fail if under 100%. python -Im coverage report --fail-under=100 diff --git a/noxfile.py b/noxfile.py index 3f792708..bcd7f4ef 100644 --- a/noxfile.py +++ b/noxfile.py @@ -17,7 +17,8 @@ def pre_commit(session: nox.Session) -> None: session.run("pre-commit", "run", "--all-files", "--show-diff-on-failure") -@nox.session(python=["pypy3.8", "3.8", "3.9", "3.10", "3.11"]) +# Keep list in-sync with ci.yml/test-linux & pyproject.toml +@nox.session(python=["pypy3.8", "3.8", "3.9", "3.10", "3.11", "3.12"]) def tests(session: nox.Session) -> None: session.install("Twisted", "coverage[toml]") posargs = list(session.posargs) diff --git a/pyproject.toml b/pyproject.toml index 11481040..9f79487a 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -12,6 +12,7 @@ name = "towncrier" description = "Building newsfiles for your project." readme = "README.rst" license = "MIT" +# Keep version list in-sync with noxfile/tests & ci.yml/test-linux. classifiers = [ "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", @@ -22,6 +23,7 @@ classifiers = [ "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", + "Programming Language :: Python :: 3.12", "Programming Language :: Python :: Implementation :: CPython", "Programming Language :: Python :: Implementation :: PyPy", ] diff --git a/src/towncrier/newsfragments/541.feature b/src/towncrier/newsfragments/541.feature new file mode 100644 index 00000000..22256fa1 --- /dev/null +++ b/src/towncrier/newsfragments/541.feature @@ -0,0 +1 @@ +Python 3.12 is now officially supported.