Skip to content
Merged
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
2 changes: 1 addition & 1 deletion .github/workflows/pre-commit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: actions/setup-python@v6
- uses: actions/setup-python@v7
with:
python-version: '3.13'
- uses: pre-commit/action@2c7b3805fd2a0fd8c1884dcaebf91fc102a13ecd #v3.0.1
Expand Down
155 changes: 69 additions & 86 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,13 @@ on:
# Allow to run this workflow manually from the Actions tab
workflow_dispatch:

defaults:
run:
# ``pwsh`` propagates only the exit code of the *last* command of a
# multi-command block, so failures on Windows go unnoticed. ``bash``
# runs with ``-eo pipefail`` and aborts the step on the first failure.
shell: bash

env:
# Weirdly, this has to be a top-level key, not ``defaults.env``
PYTHONHASHSEED: 8675309
Expand Down Expand Up @@ -105,7 +112,7 @@ jobs:
with:
persist-credentials: false
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v6
uses: actions/setup-python@v7
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
Expand All @@ -115,42 +122,36 @@ jobs:
# to save the cache. So it must come before the thing we want to use
# the cache.
###
- name: Get pip cache dir (default)
id: pip-cache-default
if: ${{ !startsWith(runner.os, 'Windows') }}
- name: Get pip cache epoch
id: pip-cache-epoch
# ``actions/cache`` never replaces an entry: "if the provided key
# matches an existing cache, a new cache is not created". A corrupt
# entry would therefore break every run that restores it until GitHub
# evicts it. Rotating the key weekly abandons such an entry instead.
run: |
echo "dir=$(pip cache dir)" >>$GITHUB_OUTPUT
echo "week=$(date -u +%G-%V)" >> "$GITHUB_OUTPUT"

- name: Get pip cache dir (Windows)
id: pip-cache-windows
if: ${{ startsWith(runner.os, 'Windows') }}
- name: Get pip cache dir
id: pip-cache
run: |
echo "dir=$(pip cache dir)" >> $Env:GITHUB_OUTPUT

- name: pip cache (default)
uses: actions/cache@v5
if: ${{ !startsWith(runner.os, 'Windows') }}
with:
path: ${{ steps.pip-cache-default.outputs.dir }}
key: ${{ runner.os }}-${{ runner.arch }}-pip-${{ matrix.python-version }}
echo "dir=$(pip cache dir)" >> "$GITHUB_OUTPUT"

- name: pip cache (Windows)
- name: pip cache
uses: actions/cache@v5
if: ${{ startsWith(runner.os, 'Windows') }}
with:
path: ${{ steps.pip-cache-windows.outputs.dir }}
key: ${{ runner.os }}-${{ runner.arch }}-pip-${{ matrix.python-version }}
path: ${{ steps.pip-cache.outputs.dir }}
key: ${{ runner.os }}-${{ runner.arch }}-pip-${{ matrix.python-version }}-${{ steps.pip-cache-epoch.outputs.week }}


- name: Install Build Dependencies (3.15)
if: startsWith(matrix.python-version, '3.15')
run: |
pip install -U pip
python -m pip install -U pip
pip install -U "setuptools >= 78.1.1,< 82" wheel twine cffi pycparser
- name: Install Build Dependencies
if: ${{ !startsWith(matrix.python-version, '3.15') }}
run: |
pip install -U pip
python -m pip install -U pip
pip install -U "setuptools >= 78.1.1,< 82" wheel twine

- name: Build AccessControl (macOS x86_64)
Expand Down Expand Up @@ -207,7 +208,7 @@ jobs:
if: ${{ !startsWith(matrix.python-version, '3.15') }}
run: |
# Install to collect dependencies into the (pip) cache.
pip install -U pip "setuptools >= 78.1.1,< 82"
python -m pip install -U pip "setuptools >= 78.1.1,< 82"
pip install .[test]

- name: Check AccessControl build
Expand Down Expand Up @@ -279,7 +280,7 @@ jobs:
with:
persist-credentials: false
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v6
uses: actions/setup-python@v7
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
Expand All @@ -289,31 +290,25 @@ jobs:
# to save the cache. So it must come before the thing we want to use
# the cache.
###
- name: Get pip cache dir (default)
id: pip-cache-default
if: ${{ !startsWith(runner.os, 'Windows') }}
- name: Get pip cache epoch
id: pip-cache-epoch
# ``actions/cache`` never replaces an entry: "if the provided key
# matches an existing cache, a new cache is not created". A corrupt
# entry would therefore break every run that restores it until GitHub
# evicts it. Rotating the key weekly abandons such an entry instead.
run: |
echo "dir=$(pip cache dir)" >>$GITHUB_OUTPUT
echo "week=$(date -u +%G-%V)" >> "$GITHUB_OUTPUT"

- name: Get pip cache dir (Windows)
id: pip-cache-windows
if: ${{ startsWith(runner.os, 'Windows') }}
- name: Get pip cache dir
id: pip-cache
run: |
echo "dir=$(pip cache dir)" >> $Env:GITHUB_OUTPUT

- name: pip cache (default)
uses: actions/cache@v5
if: ${{ !startsWith(runner.os, 'Windows') }}
with:
path: ${{ steps.pip-cache-default.outputs.dir }}
key: ${{ runner.os }}-${{ runner.arch }}-pip-${{ matrix.python-version }}
echo "dir=$(pip cache dir)" >> "$GITHUB_OUTPUT"

- name: pip cache (Windows)
- name: pip cache
uses: actions/cache@v5
if: ${{ startsWith(runner.os, 'Windows') }}
with:
path: ${{ steps.pip-cache-windows.outputs.dir }}
key: ${{ runner.os }}-${{ runner.arch }}-pip-${{ matrix.python-version }}
path: ${{ steps.pip-cache.outputs.dir }}
key: ${{ runner.os }}-${{ runner.arch }}-pip-${{ matrix.python-version }}-${{ steps.pip-cache-epoch.outputs.week }}

- name: Download AccessControl wheel (Linux/macOS)
if: "!startsWith(runner.os, 'Windows')"
Expand Down Expand Up @@ -399,7 +394,7 @@ jobs:
with:
persist-credentials: false
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v6
uses: actions/setup-python@v7
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
Expand All @@ -409,31 +404,25 @@ jobs:
# to save the cache. So it must come before the thing we want to use
# the cache.
###
- name: Get pip cache dir (default)
id: pip-cache-default
if: ${{ !startsWith(runner.os, 'Windows') }}
- name: Get pip cache epoch
id: pip-cache-epoch
# ``actions/cache`` never replaces an entry: "if the provided key
# matches an existing cache, a new cache is not created". A corrupt
# entry would therefore break every run that restores it until GitHub
# evicts it. Rotating the key weekly abandons such an entry instead.
run: |
echo "dir=$(pip cache dir)" >>$GITHUB_OUTPUT
echo "week=$(date -u +%G-%V)" >> "$GITHUB_OUTPUT"

- name: Get pip cache dir (Windows)
id: pip-cache-windows
if: ${{ startsWith(runner.os, 'Windows') }}
- name: Get pip cache dir
id: pip-cache
run: |
echo "dir=$(pip cache dir)" >> $Env:GITHUB_OUTPUT
echo "dir=$(pip cache dir)" >> "$GITHUB_OUTPUT"

- name: pip cache (default)
- name: pip cache
uses: actions/cache@v5
if: ${{ !startsWith(runner.os, 'Windows') }}
with:
path: ${{ steps.pip-cache-default.outputs.dir }}
key: ${{ runner.os }}-${{ runner.arch }}-pip-${{ matrix.python-version }}

- name: pip cache (Windows)
uses: actions/cache@v5
if: ${{ startsWith(runner.os, 'Windows') }}
with:
path: ${{ steps.pip-cache-windows.outputs.dir }}
key: ${{ runner.os }}-${{ runner.arch }}-pip-${{ matrix.python-version }}
path: ${{ steps.pip-cache.outputs.dir }}
key: ${{ runner.os }}-${{ runner.arch }}-pip-${{ matrix.python-version }}-${{ steps.pip-cache-epoch.outputs.week }}

- name: Download AccessControl wheel
uses: actions/download-artifact@v8
Expand Down Expand Up @@ -473,7 +462,7 @@ jobs:
with:
persist-credentials: false
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v6
uses: actions/setup-python@v7
with:
python-version: ${{ matrix.python-version }}
allow-prereleases: true
Expand All @@ -483,35 +472,29 @@ jobs:
# to save the cache. So it must come before the thing we want to use
# the cache.
###
- name: Get pip cache dir (default)
id: pip-cache-default
if: ${{ !startsWith(runner.os, 'Windows') }}
- name: Get pip cache epoch
id: pip-cache-epoch
# ``actions/cache`` never replaces an entry: "if the provided key
# matches an existing cache, a new cache is not created". A corrupt
# entry would therefore break every run that restores it until GitHub
# evicts it. Rotating the key weekly abandons such an entry instead.
run: |
echo "dir=$(pip cache dir)" >>$GITHUB_OUTPUT
echo "week=$(date -u +%G-%V)" >> "$GITHUB_OUTPUT"

- name: Get pip cache dir (Windows)
id: pip-cache-windows
if: ${{ startsWith(runner.os, 'Windows') }}
- name: Get pip cache dir
id: pip-cache
run: |
echo "dir=$(pip cache dir)" >> $Env:GITHUB_OUTPUT

- name: pip cache (default)
uses: actions/cache@v5
if: ${{ !startsWith(runner.os, 'Windows') }}
with:
path: ${{ steps.pip-cache-default.outputs.dir }}
key: ${{ runner.os }}-pip_manylinux-${{ matrix.image }}-${{ matrix.python-version }}
echo "dir=$(pip cache dir)" >> "$GITHUB_OUTPUT"

- name: pip cache (Windows)
- name: pip cache
uses: actions/cache@v5
if: ${{ startsWith(runner.os, 'Windows') }}
with:
path: ${{ steps.pip-cache-windows.outputs.dir }}
key: ${{ runner.os }}-pip_manylinux-${{ matrix.image }}-${{ matrix.python-version }}
path: ${{ steps.pip-cache.outputs.dir }}
key: ${{ runner.os }}-pip_manylinux-${{ matrix.image }}-${{ matrix.python-version }}-${{ steps.pip-cache-epoch.outputs.week }}


- name: Update pip
run: pip install -U pip
run: python -m pip install -U pip

- name: Build AccessControl
if: matrix.image != 'manylinux2014_i686'
Expand All @@ -537,7 +520,7 @@ jobs:
name: manylinux_${{ matrix.image }}_wheels.zip

- name: Restore pip cache permissions
run: sudo chown -R $(whoami) ${{ steps.pip-cache-default.outputs.dir }}
run: sudo chown -R $(whoami) ${{ steps.pip-cache.outputs.dir }}

- name: Prevent publishing wheels for unreleased Python versions
run: VER=$(echo '3.15' | tr -d .) && ls -al wheelhouse && sudo rm -f wheelhouse/*-cp${VER}*.whl && ls -al wheelhouse
Expand Down Expand Up @@ -582,7 +565,7 @@ jobs:
find dist/ -name "*linux_x86_64*" -type f -delete || true

- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
uses: pypa/gh-action-pypi-publish@dc37677b2e1c63e2034f94d8a5b11f265b73ba33 # v1.14.2
with:
skip-existing: true
packages-dir: dist/
Expand Down
2 changes: 1 addition & 1 deletion .meta.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# https://github.com/zopefoundation/meta/tree/master/src/zope/meta/c-code
[meta]
template = "c-code"
commit-id = "966ac0d8"
commit-id = "9333ca19"

[python]
with-windows = true
Expand Down
2 changes: 2 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ For changes before version 3.0, see ``HISTORY.rst``.
7.5 (unreleased)
----------------

- Add final support for Python 3.15.


7.4 (2026-07-13)
----------------
Expand Down
2 changes: 2 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ classifiers = [
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: 3.14",
"Programming Language :: Python :: 3.15",
"Programming Language :: Python :: Implementation :: CPython",
]
dependencies = [
Expand Down Expand Up @@ -108,4 +109,5 @@ readme = {file = ["README.rst", "CHANGES.rst"]}

[tool.zest-releaser]
create-wheel = false
extra-message = ""
upload-pypi = false
Loading