From c773217edd3009fe6f02bf4a37446bf4a9b54d8b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bal=C3=A1zs=20Re=C3=A9?= Date: Tue, 25 Jun 2024 13:11:09 +0200 Subject: [PATCH] Force to use pip<24 for Plone 5.2 ``` WARNING: Ignoring version 5.2.5 of Products.CMFPlone since it has invalid metadata: Requested Products.CMFPlone from https://files.pythonhosted.org/packages/a8/b1/7f746d0ecf0fc95c3e81585aa4f6dddca04be643509aa803754d736ab7e6/Products.CMFPlone-5.2.5-py2.py3-none-any.whl (from plone.app.contentmenu==2.3.3->-r requirements-mxdev.txt (line 8)) has invalid metadata: Expected matching RIGHT_PARENTHESIS for LEFT_PARENTHESIS, after version specifier plone.app.contentmenu (>=1.1.6dev-r22380) ~~~~~~~~~~~~^ Please use pip<24.1 if you need to use this version. ``` In connection with this, avoid using the setup-plone action because it's unclear how it can be forced to use a specific old version of pip. --- .github/workflows/test-plone-5.2.yml | 10 ++++++---- Makefile | 1 + requirements-5.2.txt | 1 + 3 files changed, 8 insertions(+), 4 deletions(-) diff --git a/.github/workflows/test-plone-5.2.yml b/.github/workflows/test-plone-5.2.yml index 027294b..a1f5d10 100644 --- a/.github/workflows/test-plone-5.2.yml +++ b/.github/workflows/test-plone-5.2.yml @@ -29,10 +29,12 @@ jobs: # python setup - name: Set up Python ${{ matrix.python-version }} with Plone 5.2.5 - uses: plone/setup-plone@v1.0.0 - with: - python-version: ${{ matrix.python-version }} - plone-version: "5.2.5" + run: | + make install-plone-5.2 + + ## Note: setup-plone action is retired, because we need to force + ## an older pip version, but the action seems to fetch the new version + ## regardless what I try. # python cache - uses: actions/cache@v1 diff --git a/Makefile b/Makefile index 8df67d6..67dcae4 100644 --- a/Makefile +++ b/Makefile @@ -106,6 +106,7 @@ install-plone-5.2: bin/mxdev config ## pip install Plone packages @echo "$(GREEN)==> Setup Build$(RESET)" cp constraints-5.2.txt constraints.txt cp requirements-5.2.txt requirements.txt + pip install pip\<24 bin/tox -e init bin/mxdev -c mx.ini bin/pip install -r requirements-mxdev.txt diff --git a/requirements-5.2.txt b/requirements-5.2.txt index 8c3fcef..625c554 100644 --- a/requirements-5.2.txt +++ b/requirements-5.2.txt @@ -1,4 +1,5 @@ -c constraints.txt +pip<24 # Cannot install new testing framework with 5.2 # -e ".[test]"