Skip to content

Commit

Permalink
Merge branch 'latest' into extra-tests
Browse files Browse the repository at this point in the history
  • Loading branch information
galabovaa committed Nov 11, 2024
2 parents 5ded22e + 02aeb70 commit 19c9a73
Show file tree
Hide file tree
Showing 118 changed files with 7,513 additions and 2,593 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/build-nuget-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ concurrency:
cancel-in-progress: true

jobs:
# macos 12 is Intel
build_macos_12:
runs-on: macos-12
# macos 13 is Intel
build_macos_13:
runs-on: macos-13
# strategy:
# matrix:
# python: [3.11]
Expand All @@ -32,7 +32,7 @@ jobs:
name: macos-x64
path: ${{runner.workspace}}/build/dotnet/Highs.Native/runtimes

# macos 14 is M1 (beta)
# macos 14 is M1
build_macos_14:
runs-on: macos-14
steps:
Expand Down Expand Up @@ -124,7 +124,7 @@ jobs:

build_windows:
runs-on: windows-latest
needs: [build_macos_12, build_macos_14, build_windows_32, build_linux, build_linux_arm64]
needs: [build_macos_13, build_macos_14, build_windows_32, build_linux, build_linux_arm64]
steps:
- uses: actions/checkout@v4
- name: Build HiGHS Windows native
Expand Down Expand Up @@ -185,7 +185,7 @@ jobs:

- name: Dotnet pack
working-directory: ${{runner.workspace}}/build/dotnet/Highs.Native
run: dotnet pack -c Release /p:Version=1.7.2
run: dotnet pack -c Release /p:Version=1.8.0

- uses: actions/upload-artifact@v4
with:
Expand Down
51 changes: 23 additions & 28 deletions .github/workflows/build-python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -105,13 +105,12 @@ jobs:
python3 -m pip install pytest
python3 -m pytest $GITHUB_WORKSPACE
# macos 12 is Intel
build_wheel_macos_12:
runs-on: macos-12
# macos 13 is Intel
build_wheel_macos_13:
runs-on: macos-13
strategy:
matrix:
python: [3.11]
python: [3.11]
steps:
- uses: actions/checkout@v4

Expand All @@ -134,12 +133,12 @@ jobs:
- name: Test highspy
run: |
python3 -m pip install pytest
python3 -m pip install pytest
python3 -m pytest $GITHUB_WORKSPACE
# macos 13 is Intel
build_wheel_macos_13:
runs-on: macos-13
# macos 14 is M1
build_wheel_macos_14:
runs-on: macos-14
strategy:
matrix:
python: [3.11]
Expand All @@ -154,7 +153,7 @@ jobs:
- name: Build wheel
run: |
python3 -m pip install cibuildwheel
python3 -m cibuildwheel --only cp311-macosx_x86_64 $GITHUB_WORKSPACE
python3 -m cibuildwheel --only cp311-macosx_arm64 $GITHUB_WORKSPACE
- name: Install wheel
run: |
Expand All @@ -167,38 +166,34 @@ jobs:
run: |
python3 -m pip install pytest
python3 -m pytest $GITHUB_WORKSPACE
# macos 14 is M1 (beta)
build_wheel_macos_14:
runs-on: macos-14
strategy:
matrix:
python: [3.11]
build_wheel_windows:
runs-on: windows-2019
steps:
- uses: actions/checkout@v4

- name: Install correct python version
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python }}
python-version: 3.9

- name: Build wheel
run: |
python3 -m pip install cibuildwheel
python3 -m cibuildwheel --only cp311-macosx_arm64 $GITHUB_WORKSPACE
python -m pip install cibuildwheel
python -m cibuildwheel --only cp39-win_amd64 $GITHUB_WORKSPACE
- name: Install wheel
run: |
ls wheelhouse
python3 --version
python3 -m pip install wheelhouse/*.whl
python3 -c "import highspy; print(dir(highspy))"
$item = Get-ChildItem wheelhouse
python -m pip install "$item"
python -c "import highspy; print(dir(highspy))"
- name: Test highspy
run: |
python3 -m pip install pytest
python3 -m pytest $GITHUB_WORKSPACE
python -m pip install pytest
python -m pytest
build_wheel_windows:
runs-on: windows-2019
steps:
Expand All @@ -207,12 +202,12 @@ jobs:
- name: Install correct python version
uses: actions/setup-python@v5
with:
python-version: 3.9
python-version: 3.13

- name: Build wheel
run: |
python -m pip install cibuildwheel
python -m cibuildwheel --only cp39-win_amd64 $GITHUB_WORKSPACE
python -m cibuildwheel --only cp313-win_amd64 $GITHUB_WORKSPACE
- name: Install wheel
run: |
Expand Down
63 changes: 35 additions & 28 deletions .github/workflows/build-wheels-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,24 @@ concurrency:
cancel-in-progress: true

jobs:
build_sdist:
name: Build source distribution
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Build sdist
shell: bash
run: pipx run build --sdist

# - name: check metadata
# run: pipx run twine check python/dist/*

- uses: actions/upload-artifact@v4
with:
name: cibw-sdist
path: python/dist/*.tar.gz

build_wheels:
name: Build wheel for ${{ matrix.python }}-${{ matrix.buildplat[1] }}
runs-on: ${{ matrix.buildplat[0] }}
Expand All @@ -30,47 +48,38 @@ jobs:
- [ubuntu-20.04, musllinux_x86_64] # No OpenBlas, no test
- [ubuntu-20.04, musllinux_i686]
- [ubuntu-20.04, musllinux_aarch64]
- [macos-12, macosx_x86_64]
- [macos-13, macosx_x86_64]
- [macos-14, macosx_arm64]
- [windows-2019, win_amd64]
- [windows-2019, win32]
python: ["cp38", "cp39","cp310", "cp311","cp312"]
python: ["cp38", "cp39","cp310", "cp311","cp312", "cp313"]

steps:
- uses: actions/checkout@v4

- name: Set up QEMU # Required for aarch64 builds
if: ${{ contains(matrix.buildplat[1], 'aarch64') }}
uses: docker/setup-qemu-action@v3
with:
platforms: all

- name: Build wheels (aarch64)
if: ${{ contains(matrix.buildplat[1], 'aarch64') }}
uses: pypa/cibuildwheel@v2.19
uses: pypa/cibuildwheel@v2.21
env:
CIBW_BUILD: ${{ matrix.python }}-${{ matrix.buildplat[1] }}
CIBW_ARCHS_LINUX: aarch64

- name: Build wheels (not aarch64)
if: ${{ !contains(matrix.buildplat[1], 'aarch64') }}
uses: pypa/cibuildwheel@v2.19
uses: pypa/cibuildwheel@v2.21
env:
CIBW_BUILD: ${{ matrix.python }}-${{ matrix.buildplat[1] }}
- uses: actions/upload-artifact@v3
with:
path: ./wheelhouse/*.whl

build_sdist:
name: Build source distribution
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Build sdist
shell: bash -l {0}
run: pipx run build --sdist

- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@v4
with:
path: dist/*.tar.gz
name: cibw-wheels-${{ matrix.python }}-${{ matrix.buildplat[1] }}
path: wheelhouse/*.whl

# upload_testpypi:
# name: >-
Expand All @@ -88,12 +97,11 @@ jobs:
# permissions:
# id-token: write # IMPORTANT: mandatory for trusted publishing
# steps:
# - uses: actions/download-artifact@v3
# - uses: actions/download-artifact@v4
# with:
# # unpacks default artifact into dist/
# # if `name: artifact` is omitted, the action will create extra parent dir
# name: artifact
# pattern: cibw-*
# path: dist
# merge-multiple: true

# - name: Download all
# uses: pypa/gh-action-pypi-publish@release/v1
Expand All @@ -107,7 +115,7 @@ jobs:
needs: [build_wheels, build_sdist]

# upload to PyPI on every tag starting with 'v'
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
# if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')

environment:
name: pypi
Expand All @@ -117,12 +125,11 @@ jobs:
id-token: write # IMPORTANT: mandatory for trusted publishing

steps:
- uses: actions/download-artifact@v3
- uses: actions/download-artifact@v4
with:
# unpacks default artifact into dist/
# if `name: artifact` is omitted, the action will create extra parent dir
name: artifact
pattern: cibw-*
path: dist
merge-multiple: true

- name: Download all
uses: pypa/gh-action-pypi-publish@release/v1
30 changes: 16 additions & 14 deletions .github/workflows/build-wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,16 @@ concurrency:
cancel-in-progress: true

jobs:
build_sdist:
name: Build source distribution
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Build sdist
shell: bash
run: pipx run build --sdist

build_wheels:
name: Build wheel for ${{ matrix.python }}-${{ matrix.buildplat[1] }}
runs-on: ${{ matrix.buildplat[0] }}
Expand All @@ -25,11 +35,11 @@ jobs:
- [ubuntu-20.04, musllinux_x86_64] # No OpenBlas, no test
- [ubuntu-20.04, musllinux_i686]
- [ubuntu-20.04, musllinux_aarch64]
- [macos-12, macosx_x86_64]
- [macos-13, macosx_x86_64]
- [macos-14, macosx_arm64]
- [windows-2019, win_amd64]
- [windows-2019, win32]
python: ["cp38", "cp39","cp310", "cp311","cp312"]
python: ["cp38", "cp39","cp310", "cp311","cp312", "cp313"]

steps:
- uses: actions/checkout@v4
Expand All @@ -38,24 +48,16 @@ jobs:
uses: docker/setup-qemu-action@v3
with:
platforms: all

- name: Build wheels (aarch64)
if: ${{ contains(matrix.buildplat[1], 'aarch64') }}
uses: pypa/cibuildwheel@v2.19
uses: pypa/cibuildwheel@v2.21
env:
CIBW_BUILD: ${{ matrix.python }}-${{ matrix.buildplat[1] }}
CIBW_ARCHS_LINUX: aarch64

- name: Build wheels (not aarch64)
if: ${{ !contains(matrix.buildplat[1], 'aarch64') }}
uses: pypa/cibuildwheel@v2.19
uses: pypa/cibuildwheel@v2.21
env:
CIBW_BUILD: ${{ matrix.python }}-${{ matrix.buildplat[1] }}

build_sdist:
name: Build source distribution
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Build sdist
shell: bash -l {0}
run: pipx run build --sdist
4 changes: 2 additions & 2 deletions .github/workflows/build-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ jobs:
# Note the current convention is to use the -S and -B options here to specify source
# and build directories, but this is only available with CMake 3.13 and higher.
# The CMake binaries on the Github Actions machines are (as of this writing) 3.12
run: cmake $GITHUB_WORKSPACE -DFAST_BUILD=OFF -DHIGHSINT64=on -DHIGHS_NO_DEFAULT_THREADS=ON
run: cmake $GITHUB_WORKSPACE -DHIGHSINT64=on -DHIGHS_NO_DEFAULT_THREADS=ON

- name: Build
working-directory: ${{runner.workspace}}/build
Expand Down Expand Up @@ -263,7 +263,7 @@ jobs:
# Note the current convention is to use the -S and -B options here to specify source
# and build directories, but this is only available with CMake 3.13 and higher.
# The CMake binaries on the Github Actions machines are (as of this writing) 3.12
run: cmake $GITHUB_WORKSPACE -DFAST_BUILD=OFF -DHIGHSINT64=on -DHIGHS_NO_DEFAULT_THREADS=ON
run: cmake $GITHUB_WORKSPACE -DHIGHSINT64=on -DHIGHS_NO_DEFAULT_THREADS=ON -DALL_TESTS=ON

- name: Build
working-directory: ${{runner.workspace}}/build
Expand Down
5 changes: 3 additions & 2 deletions .github/workflows/clang-format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ jobs:
- uses: actions/checkout@v4
- uses: DoozyX/[email protected]
with:
source: 'app/ src/Highs.h ./src/lp_data ./src/mip ./src/model ./src/simplex ./src/presolve ./src/simplex ./src/util ./src/test'
#./src/test ./interfaces'
source:
'app/ src/Highs.h ./src/lp_data ./src/mip ./src/model ./src/simplex ./src/presolve ./src/simplex ./src/util ./src/test ./src/qpsolver'
# ./src/test ./interfaces'
extensions: 'h,cpp,c'
clangFormatVersion: 18
2 changes: 1 addition & 1 deletion .github/workflows/test-fortran-macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on: [push, pull_request]

jobs:
fast_build_release:
runs-on: macos-12
runs-on: [macos-13]


steps:
Expand Down
Loading

0 comments on commit 19c9a73

Please sign in to comment.