From 677d123458be5e60a5783dd325ff2c2cb2e2be22 Mon Sep 17 00:00:00 2001 From: reneeotten Date: Sat, 18 Nov 2023 09:17:47 -0500 Subject: [PATCH] CI: test with Python 3.12 and Python 3.13-dev --- azure-pipelines.yml | 39 +++++++++++++++++++-------------------- 1 file changed, 19 insertions(+), 20 deletions(-) diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 033f17be..1714a800 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -14,7 +14,7 @@ stages: steps: - task: UsePythonVersion@0 inputs: - versionSpec: '3.11' + versionSpec: '3.12' - script: | python -m pip install --upgrade build pip setuptools wheel displayName: 'Install Python build tools and dependencies' @@ -43,7 +43,7 @@ stages: steps: - task: UsePythonVersion@0 inputs: - versionSpec: '3.11' + versionSpec: '3.12' - script: | python -m pip install --upgrade build pip setuptools wheel displayName: 'Install Python build tools' @@ -129,6 +129,8 @@ stages: python.version: '3.10' Python311: python.version: '3.11' + Python312: + python.version: '3.12' steps: - task: UsePythonVersion@0 @@ -167,7 +169,6 @@ stages: ./codecov -v -f "coverage.xml" displayName: 'Upload to codecov.io' -# Python 3.11 on Windows currently fails to build pycairo - stage: test_Windows_latest dependsOn: check_codestyle condition: succeededOrFailed() @@ -177,8 +178,8 @@ stages: vmImage: 'windows-latest' strategy: matrix: - Python310: - python.version: '3.10' + Python312: + python.version: '3.12' steps: - task: UsePythonVersion@0 @@ -213,7 +214,7 @@ stages: strategy: matrix: Python311: - python.version: '3.11' + python.version: '3.12' steps: - task: UsePythonVersion@0 @@ -239,13 +240,13 @@ stages: dependsOn: check_codestyle condition: succeededOrFailed() jobs: - - job: Python312_dev + - job: Python313_dev pool: vmImage: 'ubuntu-latest' steps: - script: | sudo add-apt-repository ppa:deadsnakes/nightly - sudo apt-get update && sudo apt-get install -y --no-install-recommends python3.12-dev python3.12-venv + sudo apt-get update && sudo apt-get install -y --no-install-recommends python3.13-dev python3.13-venv displayName: Install Python development version from the deadsnakes PPA - script: | sudo apt-get update && sudo apt-get install -yq --no-install-suggests --no-install-recommends \ @@ -254,10 +255,8 @@ stages: displayName: 'Install dependencies' - script: | export PATH=/home/vsts/.local/bin:$PATH - ##curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py - ##python3.12 get-pip.py --user - python3.12 -m ensurepip --upgrade - pip3.12 install -U build pip setuptools wheel pybind11 cython || echo -e "\043#vso[task.logissue type=warning;] Allowed failure for development version!!" + python3.13 -m ensurepip --upgrade + pip3.13 install -U build pip setuptools wheel pybind11 cython || echo -e "\043#vso[task.logissue type=warning;] Allowed failure for development version!!" displayName: 'Install build, pip, setuptools, wheel, pybind11, and cython' - script: | export PATH=/home/vsts/.local/bin:$PATH @@ -265,11 +264,11 @@ stages: wget https://github.com/numpy/numpy/releases/download/v${numpy_version}/numpy-${numpy_version}.tar.gz tar xzvf numpy-${numpy_version}.tar.gz cd numpy-${numpy_version} - python3.12 setup.py install --user || echo -e "\043#vso[task.logissue type=warning;] Allowed failure for development version!!" + python3.13 setup.py install --user || echo -e "\043#vso[task.logissue type=warning;] Allowed failure for development version!!" displayName: 'Install latest available version of NumPy' - script: | export PATH=/home/vsts/.local/bin:$PATH - pip3.12 install -U pythran || echo -e "\043#vso[task.logissue type=warning;] Allowed failure for development version!!" + pip3.13 install -U pythran || echo -e "\043#vso[task.logissue type=warning;] Allowed failure for development version!!" displayName: 'Install pythran' - script: | export PATH=/home/vsts/.local/bin:$PATH @@ -277,24 +276,24 @@ stages: wget https://github.com/scipy/scipy/releases/download/v${scipy_version}/scipy-${scipy_version}.tar.gz tar xzvf scipy-${scipy_version}.tar.gz cd scipy-${scipy_version} - python3.12 setup.py install --user || echo -e "\043#vso[task.logissue type=warning;] Allowed failure for development version!!" + python3.13 setup.py install --user || echo -e "\043#vso[task.logissue type=warning;] Allowed failure for development version!!" displayName: 'Install latest available version of SciPy' - script: | export PATH=/home/vsts/.local/bin:$PATH # remove numdifftools for now as it pulls in statsmodels, that wants to build with NumPy 1.14.5 - pip3.12 install asteval uncertainties dill emcee flaky pytest pytest-cov || echo -e "\043#vso[task.logissue type=warning;] Allowed failure for development version!!" + pip3.13 install asteval uncertainties dill emcee flaky pytest pytest-cov || echo -e "\043#vso[task.logissue type=warning;] Allowed failure for development version!!" displayName: 'Install latest available version of Python dependencies' - script: | - python3.12 -m build - python3.12 -m pip install '.[test]' --user || echo -e "\043#vso[task.logissue type=warning;] Allowed failure for development version!!" + python3.13 -m build + python3.13 -m pip install '.[test]' --user || echo -e "\043#vso[task.logissue type=warning;] Allowed failure for development version!!" displayName: 'Build wheel/sdist and install lmfit' - script: | export PATH=/home/vsts/.local/bin:$PATH - pip3.12 list || echo -e "\043#vso[task.logissue type=warning;] Allowed failure for development version!!" + pip3.13 list || echo -e "\043#vso[task.logissue type=warning;] Allowed failure for development version!!" displayName: 'List installed Python packages' - script: | export PATH=/home/vsts/.local/bin:$PATH - pip3.12 install pytest-azurepipelines + pip3.13 install pytest-azurepipelines cd $(Agent.BuildDirectory)/s/tests pytest || echo -e "\043#vso[task.logissue type=warning;] Allowed failure for development version!!" displayName: 'Run test-suite'