Skip to content

numpy 2.x compatibility #83

numpy 2.x compatibility

numpy 2.x compatibility #83

Workflow file for this run

# This workflow will install Python dependencies, run tests and lint with a single version of Python
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
name: test
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
dummy-build:
runs-on: ubuntu-latest
strategy:
matrix:
mpi: ['mpi4py', 'none']
python-version: [ '3.8', '3.9', '3.10']
steps:
- uses: actions/checkout@v4
- uses: conda-incubator/setup-miniconda@v3
with:
python-version: ${{ matrix.python-version }}
- name: Install base dependencies
shell: bash -l {0}
run: |
# $CONDA is an environment variable pointing to the root of the miniconda directory
# $CONDA/bin/conda env update --file environment.yml --name base
# Install requirements except for h5writer and pint which must be from pip
pip install Pint
conda install --yes h5py pexpect pyqtgraph scipy pyzmq tornado pytz pyqt
pip install h5writer
- name: Install mpi
shell: bash -l {0}
run: conda install --yes ${{ matrix.mpi }}
if: matrix.mpi != 'none'
- name: Lint with flake8
shell: bash -l {0}
run: |
conda install flake8
# stop the build if there are Python syntax errors or undefined names
# $CONDA/bin/flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
# $CONDA/bin/flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Test with pytest
shell: bash -l {0}
run: |
conda install pytest codecov pytest-cov
pytest --cov=./ --cov-report=xml
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v3
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}