Fix ci #101
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| 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.9] | |
| config: [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@v4.1.6 | |
| 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 | |
| conda install numpy scipy conda-forge::cython pytorch::pytorch | |
| - 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 | |
| # windows has problem with memory and 2 passes... | |
| - name: Build (Release) | |
| if: matrix.config == 'Release' && runner.os != 'Windows' | |
| run: | | |
| pip install . -v | |
| # macos segfaults??? | |
| - name: Tests | |
| if: matrix.name == 'Linux' || matrix.name == 'MacOS' || (matrix.config == 'Debug' && runner.os == 'Windows') | |
| run: | | |
| python test/test_basic.py |