Skip to content

Bring python binding back to work #98

Bring python binding back to work

Bring python binding back to work #98

Workflow file for this run

name: Build
on: [push, pull_request]
jobs:
Build:
name: ${{ matrix.name }} Python ${{ matrix.python-version }} (${{ matrix.config }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macOS-latest]
python-version: [3.7, 3.8]
config: [Debug, Release]
include:
- os: ubuntu-latest
name: Linux
- os: windows-latest
name: Windows
- os: macOS-latest
name: MacOS
env:
if: runner.os == 'Windows'
USE_CHOLMOD: 0
steps:
- name: Checkout repository
uses: actions/checkout@v2
with:
fetch-depth: 10
- name: Setup NMake (Windows)
if: runner.os == 'Windows'
uses: ilammy/msvc-dev-cmd@v1
- name: Stetup Conda
uses: s-weigand/setup-conda@v1
with:
update-conda: true
python-version: ${{ matrix.python-version }}
conda-channels: anaconda, conda-forge
- name: Install Dependencies
run: |
conda install numpy libblas libcblas suitesparse plotly -y
- name: Envs (Windows)
if: runner.os == 'Windows'
run: |
echo "CMAKE_GENERATOR=NMake Makefiles" >> $GITHUB_ENV
echo "CXX=cl.exe" >> $GITHUB_ENV
echo "CC=cl.exe" >> $GITHUB_ENV
echo "USE_CHOLMOD=0" >> $GITHUB_ENV
conda init powershell
- name: Build (Debug)
if: matrix.config == 'Debug'
run: |
python setup.py build --debug install
# windows has problem with memory and 2 passes...
- name: Build (Release)
if: matrix.config == 'Release' && runner.os != 'Windows'
run: |
python setup.py build install
# macos segfaults???
- name: Tests
if: matrix.name == 'Linux' || matrix.name == 'MacOS' || (matrix.config == 'Debug' && runner.os == 'Windows')
run: |
python test/test_bending.py