From 31842fee3e876dc5684bd9259cfcacdd18944690 Mon Sep 17 00:00:00 2001 From: Jens Vagelpohl Date: Thu, 30 May 2024 16:56:17 +0200 Subject: [PATCH 1/5] - try Python 3.13 --- .github/workflows/tests.yml | 3 +++ .meta.toml | 6 +++--- constraints.txt | 9 +++++++-- requirements-full.txt | 9 +++++++-- tox.ini | 3 ++- versions-prod.cfg | 22 ++++++++++++++++++++-- 6 files changed, 42 insertions(+), 10 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 391637c1b7..91aea96dbc 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -29,6 +29,7 @@ jobs: - ["3.10", "py310"] - ["3.11", "py311"] - ["3.12", "py312"] + - ["3.13", "py313"] - ["3.9", "docs"] - ["3.9", "coverage"] exclude: @@ -40,6 +41,7 @@ jobs: - { os: ["macos", "macos-latest"], config: ["3.9", "lint"] } - { os: ["macos", "macos-latest"], config: ["3.9", "docs"] } - { os: ["macos", "macos-latest"], config: ["3.9", "coverage"] } + - { os: ["macos", "macos-latest"], config: ["3.13", "py313"] } runs-on: ${{ matrix.os[1] }} if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name @@ -50,6 +52,7 @@ jobs: uses: actions/setup-python@v5 with: python-version: ${{ matrix.config[0] }} + allow-prereleases: true - name: Pip cache uses: actions/cache@v4 with: diff --git a/.meta.toml b/.meta.toml index 45294331e3..78591f6c03 100644 --- a/.meta.toml +++ b/.meta.toml @@ -2,7 +2,7 @@ # https://github.com/zopefoundation/meta/tree/master/config/zope-product [meta] template = "zope-product" -commit-id = "8d837c89" +commit-id = "6cd77955" [python] with-pypy = false @@ -10,7 +10,7 @@ with-docs = true with-sphinx-doctests = false with-windows = true with-macos = true -with-future-python = false +with-future-python = true [coverage] fail-under = 80 @@ -30,7 +30,7 @@ additional-config = [ [tox] testenv-deps = [ - "cffi", + "cffi >= 1.17.0rc1", "# The universal2 environment is for Python on macOS built with", "# universal2 mode instead of architecture-specific. These dependencies", "# must be installed separately, zc.buildout is incompatible with the", diff --git a/constraints.txt b/constraints.txt index 8b182d23f1..0472e5f8e4 100644 --- a/constraints.txt +++ b/constraints.txt @@ -11,7 +11,12 @@ MultiMapping==5.0 Paste==3.10.1 PasteDeploy==3.1.0 Persistence==5.0 -RestrictedPython==7.1 +RestrictedPython==7.1; python_version == '3.10' +RestrictedPython==7.1; python_version == '3.11' +RestrictedPython==7.1; python_version == '3.12' +RestrictedPython==7.1; python_version == '3.8' +RestrictedPython==7.1; python_version == '3.9' +RestrictedPython==7.2a1.dev0; python_version > '3.12' WSGIProxy2==0.5.1 WebOb==1.8.7 WebTest==3.0.0 @@ -19,7 +24,7 @@ ZConfig==4.1 ZODB==6.0 Zope2==4.0 beautifulsoup4==4.12.3 -cffi==1.16.0 +cffi==1.17.0rc1 multipart==0.2.4 persistent==6.0 pycparser==2.22 diff --git a/requirements-full.txt b/requirements-full.txt index 05daad6d43..eba02dad76 100644 --- a/requirements-full.txt +++ b/requirements-full.txt @@ -12,7 +12,12 @@ MultiMapping==5.0 Paste==3.10.1 PasteDeploy==3.1.0 Persistence==5.0 -RestrictedPython==7.1 +RestrictedPython==7.1; python_version == '3.10' +RestrictedPython==7.1; python_version == '3.11' +RestrictedPython==7.1; python_version == '3.12' +RestrictedPython==7.1; python_version == '3.8' +RestrictedPython==7.1; python_version == '3.9' +RestrictedPython==7.2a1.dev0; python_version > '3.12' WSGIProxy2==0.5.1 WebOb==1.8.7 WebTest==3.0.0 @@ -20,7 +25,7 @@ ZConfig==4.1 ZODB==6.0 Zope2==4.0 beautifulsoup4==4.12.3 -cffi==1.16.0 +cffi==1.17.0rc1 multipart==0.2.4 persistent==6.0 pycparser==2.22 diff --git a/tox.ini b/tox.ini index 27ff40a780..f2e188c03e 100644 --- a/tox.ini +++ b/tox.ini @@ -10,6 +10,7 @@ envlist = py310 py311 py312 + py313 docs coverage pre-commit @@ -20,7 +21,7 @@ deps = setuptools < 69 zc.buildout >= 3.0.1 wheel > 0.37 - cffi + cffi >= 1.17.0rc1 # The universal2 environment is for Python on macOS built with # universal2 mode instead of architecture-specific. These dependencies # must be installed separately, zc.buildout is incompatible with the diff --git a/versions-prod.cfg b/versions-prod.cfg index f630e925b7..15d01c3606 100644 --- a/versions-prod.cfg +++ b/versions-prod.cfg @@ -16,14 +16,14 @@ MultiMapping = 5.0 Paste = 3.10.1 PasteDeploy = 3.1.0 Persistence = 5.0 -RestrictedPython = 7.1 +RestrictedPython = 7.2a1.dev0 WebTest = 3.0.0 WSGIProxy2 = 0.5.1 WebOb = 1.8.7 ZConfig = 4.1 ZODB = 6.0 beautifulsoup4 = 4.12.3 -cffi = 1.16.0 +cffi = 1.17.0rc1 multipart = 0.2.4 persistent = 6.0 pycparser = 2.22 @@ -85,3 +85,21 @@ zope.viewlet = 5.0 [versions:python38] # Chameleon >= 4.5 requires Python 3.9 Chameleon = 4.4.4 +# Use newest final release +RestrictedPython = 7.1 + +[versions:python39] +# Use newest final release +RestrictedPython = 7.1 + +[versions:python310] +# Use newest final release +RestrictedPython = 7.1 + +[versions:python311] +# Use newest final release +RestrictedPython = 7.1 + +[versions:python312] +# Use newest final release +RestrictedPython = 7.1 From 5949203d776b85b48c11febc2b70ee974e40b52b Mon Sep 17 00:00:00 2001 From: Jens Vagelpohl Date: Fri, 31 May 2024 09:22:22 +0200 Subject: [PATCH 2/5] - use legacy-cgi module to overcome WebOb issue --- setup.py | 1 + versions.cfg | 1 + 2 files changed, 2 insertions(+) diff --git a/setup.py b/setup.py index c16f60dc47..50c48aa1e5 100644 --- a/setup.py +++ b/setup.py @@ -122,6 +122,7 @@ def _read_file(filename): 'zope.traversing', 'zope.viewlet', 'multipart', + 'legacy-cgi; python_version > "3.12"', ], include_package_data=True, zip_safe=False, diff --git a/versions.cfg b/versions.cfg index ee828b30f5..150a679fd3 100644 --- a/versions.cfg +++ b/versions.cfg @@ -25,6 +25,7 @@ five.localsitemanager = 4.0 idna = 3.7 imagesize = 1.4.1 importlib-metadata = 7.1.0 +legacy-cgi = 2.6 mr.developer = 2.0.2 packaging = 24.0 plone.recipe.command = 1.1 From f66aa3e2f68abbd76e5cee8a6e857de6a77dd25d Mon Sep 17 00:00:00 2001 From: Jens Vagelpohl Date: Fri, 31 May 2024 09:29:15 +0200 Subject: [PATCH 3/5] - there's no reason to exclude future_python on macOS anymore --- .github/workflows/tests.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 91aea96dbc..bb945227c3 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -41,7 +41,6 @@ jobs: - { os: ["macos", "macos-latest"], config: ["3.9", "lint"] } - { os: ["macos", "macos-latest"], config: ["3.9", "docs"] } - { os: ["macos", "macos-latest"], config: ["3.9", "coverage"] } - - { os: ["macos", "macos-latest"], config: ["3.13", "py313"] } runs-on: ${{ matrix.os[1] }} if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name != github.event.pull_request.base.repo.full_name From 368fcf238f8966388062127ef751bf9aaac15f71 Mon Sep 17 00:00:00 2001 From: Jens Vagelpohl Date: Fri, 31 May 2024 10:49:05 +0200 Subject: [PATCH 4/5] - use latest zope.testbrowser and remove dependency on legacy-cgi --- constraints.txt | 2 +- requirements-full.txt | 2 +- setup.py | 1 - versions-prod.cfg | 2 +- 4 files changed, 3 insertions(+), 4 deletions(-) diff --git a/constraints.txt b/constraints.txt index 0472e5f8e4..f1417a392d 100644 --- a/constraints.txt +++ b/constraints.txt @@ -78,7 +78,7 @@ zope.size==5.0 zope.structuredtext==5.0 zope.tal==5.0.1 zope.tales==6.0 -zope.testbrowser==6.0 +zope.testbrowser==7.0 zope.testing==5.0.1 zope.traversing==5.0 zope.viewlet==5.0 diff --git a/requirements-full.txt b/requirements-full.txt index eba02dad76..2d254b4c4b 100644 --- a/requirements-full.txt +++ b/requirements-full.txt @@ -79,7 +79,7 @@ zope.size==5.0 zope.structuredtext==5.0 zope.tal==5.0.1 zope.tales==6.0 -zope.testbrowser==6.0 +zope.testbrowser==7.0 zope.testing==5.0.1 zope.traversing==5.0 zope.viewlet==5.0 diff --git a/setup.py b/setup.py index 50c48aa1e5..c16f60dc47 100644 --- a/setup.py +++ b/setup.py @@ -122,7 +122,6 @@ def _read_file(filename): 'zope.traversing', 'zope.viewlet', 'multipart', - 'legacy-cgi; python_version > "3.12"', ], include_package_data=True, zip_safe=False, diff --git a/versions-prod.cfg b/versions-prod.cfg index 15d01c3606..c0470a0f92 100644 --- a/versions-prod.cfg +++ b/versions-prod.cfg @@ -77,7 +77,7 @@ zope.size = 5.0 zope.structuredtext = 5.0 zope.tal = 5.0.1 zope.tales = 6.0 -zope.testbrowser = 6.0 +zope.testbrowser = 7.0 zope.testing = 5.0.1 zope.traversing = 5.0 zope.viewlet = 5.0 From 796d63170f10568dfc2ccc9ec2d7e44d8c37f7da Mon Sep 17 00:00:00 2001 From: Jens Vagelpohl Date: Fri, 31 May 2024 10:52:33 +0200 Subject: [PATCH 5/5] - add explanatory note for legacy-cgi version pin --- versions.cfg | 1 + 1 file changed, 1 insertion(+) diff --git a/versions.cfg b/versions.cfg index 150a679fd3..f987e61097 100644 --- a/versions.cfg +++ b/versions.cfg @@ -25,6 +25,7 @@ five.localsitemanager = 4.0 idna = 3.7 imagesize = 1.4.1 importlib-metadata = 7.1.0 +# Required by zope.testbrowser on Python 3.13 because WebOb still uses cgi. legacy-cgi = 2.6 mr.developer = 2.0.2 packaging = 24.0