reverse order of conda-forge and defaults #5
This file contains 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 and Test Using Conda | |
on: | |
push: | |
# branches: [master, devel] | |
branches: [master] | |
workflow_dispatch: | |
# # schedule: | |
# # # * is a special character in YAML so you have to quote this string | |
# # - cron: '*/0 * * * *' # run once a day | |
jobs: | |
pyapprox_unit_tests: | |
name: Setup Pyapprox dependencies with conda | |
runs-on: ${{ matrix.os }} | |
strategy: | |
fail-fast: false | |
matrix: | |
# os: [ubuntu-latest] | |
# pin to python-3.7.16 because github actions has a bug with _bz2 on | |
# ubunutu for 3.7.17 | |
# quotes needed around two-digit versions | |
python-version: [3.8, 3.9, '3.10', '3.11'] | |
os: [ubuntu-latest, macos-latest] | |
# python-version: [3.7, 3.8] #3.8 currently fails due to numpy error | |
# solely experienced when using github actions ValueError: | |
# numpy.ndarray size changed, may indicate binary incompatibility. | |
# Expected 96 from C header, got 88 from PyObject | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Setup Miniconda with Python ${{ matrix.python-version }} on ${{ matrix.os }} | |
uses: conda-incubator/setup-miniconda@v2 | |
with: | |
activate-environment: pyapprox-base | |
python-version: ${{ matrix.python-version }} | |
# channels: defaults,conda-forge | |
channels: defaults | |
environment-file: environment.yml | |
auto-update-conda: true | |
# use-only-tar-bz2: true | |
auto-activate-base: false | |
- name: Conda list | |
shell: bash -l {0} # - l {0} is needed to activate created env | |
run: | | |
conda list | |
conda env list | |
- name: Setup PyApprox | |
shell: bash -l {0} | |
run: | | |
pip install -e . | |
- name: Test PyApprox | |
shell: bash -l {0} | |
run: | | |
pytest -s --cov-report term --cov=pyapprox | |
# -s disables capturing stdout so print statements print to screen | |
# python setup.py test |