From 448f0f916a06e361edb5b82ee800653c28ac2a99 Mon Sep 17 00:00:00 2001 From: Tobias Diez Date: Wed, 1 Nov 2023 08:44:11 +0800 Subject: [PATCH 1/5] Add Python 3.12 to CI --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 2a6b6dc..fdedf82 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -12,7 +12,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: ["3.8", "3.9", "3.10", "3.11"] + python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"] cython: ["cython", "cython<3.0.0"] steps: - uses: actions/checkout@v2 From 262c15882e76cfb6d17fecb9a5cd1225f1dd572c Mon Sep 17 00:00:00 2001 From: Tobias Diez Date: Wed, 1 Nov 2023 08:44:59 +0800 Subject: [PATCH 2/5] Add Python 3.12 in setup.cfg --- setup.cfg | 1 + 1 file changed, 1 insertion(+) diff --git a/setup.cfg b/setup.cfg index 23c2dc8..10092be 100644 --- a/setup.cfg +++ b/setup.cfg @@ -20,6 +20,7 @@ classifiers = Programming Language :: Python :: 3.9 Programming Language :: Python :: 3.10 Programming Language :: Python :: 3.11 + Programming Language :: Python :: 3.12 keywords = polyhedron polytope From 0d1d4f2f312cff73fd41f2a47eed01b9e7756e31 Mon Sep 17 00:00:00 2001 From: Vincent Delecroix Date: Wed, 1 Nov 2023 09:26:24 +0100 Subject: [PATCH 3/5] fix pypi and sphinx urls --- README.rst | 9 +++++---- docs/source/index.rst | 2 +- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/README.rst b/README.rst index 8f9ff01..e8ad7ea 100644 --- a/README.rst +++ b/README.rst @@ -44,7 +44,8 @@ The available objects and functions from the `ppl` Python module are: Installation ------------ -The project is available at `Python Package Index `_ and + +The project is available at `Python Package Index `_ and can be installed with pip:: $ pip install pplpy @@ -76,7 +77,7 @@ Documentation An online version of the documentation is available at https://www.sagemath.org/pplpy/ -Compiling the html documentation requires make and `sphinx `_. +Compiling the html documentation requires make and `sphinx `_. Before building the documentation, you need to install the pplpy package (sphinx uses Python introspection). The documentation source code is contained in the repository `docs` where there is a standard Makefile with a target `html`. Running `make html` in the `docs` repository builds the documentation @@ -96,9 +97,9 @@ Requirements - `Cython `_ (tested with both 0.29 and 3.0) -- `cysignals `_ +- `cysignals `_ -- `gmpy2 `_ +- `gmpy2 `_ On Debian/Ubuntu systems the dependencies can be installed with:: diff --git a/docs/source/index.rst b/docs/source/index.rst index 2e4ad93..f55d874 100644 --- a/docs/source/index.rst +++ b/docs/source/index.rst @@ -6,7 +6,7 @@ Welcome to pplpy's documentation! Installation ------------ -pplpy is available from the `Python Package Index `_. You can hence install it with:: +pplpy is available from the `Python Package Index `_. You can hence install it with:: $ pip install pplpy From e010a30892b33234355fe36cd45c1d32d5d5d6cb Mon Sep 17 00:00:00 2001 From: Vincent Delecroix Date: Wed, 1 Nov 2023 09:41:24 +0100 Subject: [PATCH 4/5] ignore auto-generated sphinx urls --- .github/workflows/doc.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/doc.yml b/.github/workflows/doc.yml index dad10f9..7052254 100644 --- a/.github/workflows/doc.yml +++ b/.github/workflows/doc.yml @@ -39,7 +39,8 @@ jobs: sleep 1 # We ignore _modules since sphinx puts all modules in the module # overview but does not generate pages for .pyx modules. - linkchecker --check-extern --ignore-url=_modules/ http://localhost:8880 + # We also ignore a url that is generated by sphinx itself (version 7.2.6). + linkchecker --check-extern --ignore-url='_modules/|https://www.sphinx-doc.org/' http://localhost:8880 - uses: JamesIves/github-pages-deploy-action@3.7.1 with: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From 46fa129075a5c1d6cd52f08522f4dcb059965e21 Mon Sep 17 00:00:00 2001 From: Vincent Delecroix Date: Wed, 1 Nov 2023 21:45:06 +0100 Subject: [PATCH 5/5] install gmpy2 via pip for python-3.12 --- .github/workflows/test.yml | 18 ++++++++++++++++-- environment.test.yml | 1 + 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index fdedf82..91bfa90 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -14,6 +14,9 @@ jobs: matrix: python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"] cython: ["cython", "cython<3.0.0"] + exclude: + - python-version: 3.12 + cython: cython<3.0.0 steps: - uses: actions/checkout@v2 with: { submodules: recursive } @@ -22,8 +25,19 @@ jobs: - name: Install pplpy dependencies shell: bash -l {0} run: | - mamba install --quiet setuptools gmpy2 cysignals ppl "${{matrix.cython}}" - conda list + mamba install --quiet setuptools cysignals ppl gmp mpfr mpc "${{matrix.cython}}" + - name: Install gmpy2 via mamba + shell: bash -l {0} + if: ${{ matrix.python-version != '3.12' }} + run: | + mamba install --quiet gmpy2 + python -c 'import gmpy2; print(gmpy2.version())' + - name: Install gmpy2 via pip + shell: bash -l {0} + if: ${{ matrix.python-version == '3.12' }} + run: | + pip install --pre gmpy2==2.2.0a1 + python -c 'import gmpy2; print(gmpy2.version())' - name: Install pplpy shell: bash -l {0} run: | diff --git a/environment.test.yml b/environment.test.yml index bc8aba6..0fba3b2 100644 --- a/environment.test.yml +++ b/environment.test.yml @@ -4,6 +4,7 @@ channels: - defaults dependencies: - sphinx + - pip - pip: - linkchecker - cython-lint