Skip to content

Commit 3b12fc5

Browse files
committed
Update build
1 parent dc80cc2 commit 3b12fc5

File tree

2 files changed

+39
-58
lines changed

2 files changed

+39
-58
lines changed

.github/workflows/build.yml

Lines changed: 3 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@ jobs:
2222
steps:
2323
- uses: actions/checkout@v4
2424
- uses: actions/setup-python@v5
25-
# with:
26-
# python-version: 3.8
2725
- run: pip install -r requirements.txt
2826

2927

@@ -36,17 +34,7 @@ jobs:
3634
fail-fast: false
3735
matrix:
3836
os: [ ubuntu-20.04, macos-13, windows-2022 ]
39-
python-version: ["3.9", "3.10", "3.11", "3.12"]
40-
include:
41-
# These are intended to just add their extra parameter to existing matrix combinations;
42-
# see https://docs.github.com/en/actions/writing-workflows/workflow-syntax-for-github-actions#jobsjob_idstrategymatrixinclude
43-
- os: ubuntu-22.04
44-
python-version: 3.12
45-
openmp: "True"
46-
single_action_config: false
47-
- os: macos-13
48-
python-version: 3.12
49-
single_action_config: true
37+
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
5038

5139
env:
5240
RUNNER_OS: ${{ matrix.os }}
@@ -89,18 +77,12 @@ jobs:
8977
fail-fast: false
9078
matrix:
9179
os: [ ubuntu-20.04, macos-13, windows-2022 ]
92-
python-version: ["3.9", "3.10", "3.11", "3.12"]
93-
include:
94-
# This is intended to just add the single_action_config parameter to one existing combination;
95-
# see https://docs.github.com/en/actions/writing-workflows/workflow-syntax-for-github-actions#jobsjob_idstrategymatrixinclude
96-
- os: ubuntu-22.04
97-
python-version: 3.12
98-
single_action_config: true
80+
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
81+
9982
env:
10083
RUNNER_OS: ${{ matrix.os }}
10184
PYTHON_VERSION: ${{ matrix.python-version }}
10285
SINGLE_ACTION_CONFIG: "${{ matrix.single_action_config == 'True' }}"
103-
PIP_INSTALL: "${{ matrix.python-version == '3.11' }}"
10486
PYPI_SERVER: ${{ secrets.PYPI_SERVER }}
10587
PYPI_USER: ${{ secrets.PYPI_USER }}
10688
PYPI_PASSWORD: ${{ secrets.PYPI_PASSWORD }}

continuous_integration/install_dependencies.sh

Lines changed: 36 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -9,54 +9,53 @@ conda config --set remote_connect_timeout_secs 30.0
99
conda config --set remote_max_retries 10
1010
conda config --set remote_backoff_factor 2
1111
conda config --set remote_read_timeout_secs 120.0
12+
conda install mkl pip pytest pytest-cov hypothesis openblas "setuptools>65.5.1"
1213

13-
if [[ "$PYTHON_VERSION" == "3.8" ]] && [[ "$RUNNER_OS" == "macos-11" ]]; then
14-
conda install scipy=1.3 numpy=1.18 mkl pip pytest pytest-cov lapack ecos scs osqp cvxopt proxsuite "setuptools>68.1.0" pybind11
15-
elif [[ "$PYTHON_VERSION" == "3.8" ]]; then
16-
conda install scipy=1.3 numpy=1.18 mkl pip pytest pytest-cov lapack ecos scs osqp cvxopt proxsuite "setuptools>68.1.0" pybind11
17-
elif [[ "$PYTHON_VERSION" == "3.9" ]]; then
18-
# The earliest version of numpy that works is 1.19.
19-
# Given numpy 1.19, the earliest version of scipy we can use is 1.5.
20-
conda install scipy=1.5 numpy=1.19 mkl pip pytest lapack ecos scs osqp cvxopt proxsuite "setuptools>68.1.0" pybind11
21-
elif [[ "$PYTHON_VERSION" == "3.10" ]]; then
22-
# The earliest version of numpy that works is 1.21.
23-
# Given numpy 1.21, the earliest version of scipy we can use is 1.7.
24-
conda install scipy=1.7 numpy=1.21 mkl pip pytest lapack ecos scs osqp cvxopt proxsuite "setuptools>68.1.0" pybind11
25-
elif [[ "$PYTHON_VERSION" == "3.11" ]]; then
26-
# The earliest version of numpy that works is 1.23.4.
27-
# Given numpy 1.23.4, the earliest version of scipy we can use is 1.9.3.
28-
conda install scipy=1.9.3 numpy=1.23.4 mkl pip pytest lapack ecos scs cvxopt proxsuite "setuptools>68.1.0" pybind11
29-
elif [[ "$PYTHON_VERSION" == "3.12" ]]; then
30-
# The earliest version of numpy that works is 1.26.4
31-
# Given numpy 1.26.4, the earliest version of scipy we can use is 1.9.3.
32-
conda install scipy=1.11.3 numpy=1.26.4 mkl pip pytest lapack ecos scs cvxopt proxsuite daqp "setuptools>68.1.0" pybind11
14+
if [[ "$PYTHON_VERSION" != "3.13" ]]; then
15+
conda install ecos scs proxsuite daqp
16+
python -m pip install coptpy==7.1.7 gurobipy piqp clarabel osqp highspy
17+
else
18+
# only install the essential solvers for Python 3.13.
19+
conda install scs
20+
python -m pip install clarabel osqp
3321
fi
3422

35-
if [[ "$PYTHON_VERSION" == "3.12" ]]; then
36-
python -m pip install coptpy gurobipy piqp osqp clarabel
37-
elif [[ "$PYTHON_VERSION" == "3.11" ]]; then
38-
python -m pip install coptpy gurobipy cplex piqp osqp diffcp "ortools>=9.7,<9.10" clarabel
39-
# Python 3.8 on Windows will uninstall NumPy 1.16 and install NumPy 1.24 without the exception.
40-
elif [[ "$RUNNER_OS" == "Windows" ]] && [[ "$PYTHON_VERSION" == "3.8" ]]; then
41-
python -m pip install gurobipy clarabel osqp
42-
elif [[ "$PYTHON_VERSION" == "3.8" ]] && [[ "$RUNNER_OS" != "macos-11" ]]; then
43-
python -m pip install gurobipy clarabel piqp
23+
# Install newest stable versions for Python 3.13.
24+
if [[ "$PYTHON_VERSION" == "3.13" ]]; then
25+
conda install scipy numpy
4426
else
45-
python -m pip install "ortools>=9.3,<9.10" coptpy sdpa-python diffcp gurobipy clarabel sdpa-python
27+
conda install scipy=1.13.0 numpy=1.26.4
28+
fi
29+
30+
if [[ "$PYTHON_VERSION" == "3.11" ]]; then
31+
python -m pip install cplex "ortools>=9.7,<9.12"
32+
fi
33+
34+
if [[ "$RUNNER_OS" == "Windows" ]] && [[ "$PYTHON_VERSION" != "3.13" ]]; then
35+
# SDPA with OpenBLAS backend does not pass LP5 on Windows
36+
python -m pip install sdpa-multiprecision
37+
fi
38+
39+
if [[ "$RUNNER_OS" != "Windows" ]] && [[ "$PYTHON_VERSION" != "3.13" ]]; then
40+
conda install cvxopt
41+
fi
42+
43+
if [[ "$PYTHON_VERSION" == "3.12" ]] && [[ "$RUNNER_OS" != "Windows" ]]; then
44+
# cylp has no wheels for Windows
45+
python -m pip install cylp pyscipopt==5.2.1
4646
fi
4747

48-
# cylp has wheels for all versions 3.7 - 3.10, except for 3.7 on Windows
49-
if [[ "$PYTHON_VERSION" != "3.11" ]] && [[ "$RUNNER_OS" != "Windows" ]]; then
50-
python -m pip install cylp
48+
if [[ "$PYTHON_VERSION" == "3.10" ]] && [[ "$RUNNER_OS" != "Windows" ]]; then
49+
# SDPA didn't pass LP5 on Ubuntu for Python 3.9 and 3.12
50+
python -m pip install sdpa-python
5151
fi
5252

53-
# SCIP only works with scipy >= 1.5 due to dependency conflicts when installing on Linux/macOS
54-
if [[ "$PYTHON_VERSION" == "3.9" ]] && [[ "$RUNNER_OS" == "Windows" ]]; then
55-
conda install pyscipopt
53+
if [[ "$PYTHON_VERSION" == "3.11" ]] && [[ "$RUNNER_OS" != "macOS" ]]; then
54+
python -m pip install xpress==9.4.3
5655
fi
5756

5857
# Only install Mosek if license is available (secret is not copied to forks)
59-
if [[ -n "$MOSEK_CI_BASE64" ]] && [[ "$PYTHON_VERSION" != "3.11" ]]; then
58+
if [[ -n "$MOSEK_CI_BASE64" ]] && [[ "$PYTHON_VERSION" != "3.13" ]]; then
6059
python -m pip install mosek
6160
fi
6261

0 commit comments

Comments
 (0)