Skip to content

Installation updates to README and .github/workflows (#637) #9

Installation updates to README and .github/workflows (#637)

Installation updates to README and .github/workflows (#637) #9

name: Test conda-venv install
on:
push:
paths:
- 'envs/*.yml'
- '.github/workflows/test-conda-venv-install.yml'
jobs:
build:
name: ${{ matrix.os }}${{ matrix.tf-label }}-py${{ matrix.python-version-nd }}
runs-on: ${{ matrix.os }}
defaults:
run:
shell: bash -l {0}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
python-version: [3.7, 3.8, 3.9]
tf-label: ['', '-tf']
include:
- python-version: 3.7
python-version-nd: 37
- python-version: 3.8
python-version-nd: 38
- python-version: 3.9
python-version-nd: 39
- tf-label: '-tf'
tf-label-pip: '[tf]'
steps:
- name: checkout repository
uses: actions/checkout@v2
- name: Display Python version
run: python -c "import sys; print(sys.version)"
- name: create environment
uses: conda-incubator/setup-miniconda@v2
with:
channels: defaults
auto-activate-base: false
activate-environment: causalml${{ matrix.tf-label }}-py${{ matrix.python-version-nd }}
environment-file: envs/environment${{ matrix.tf-label }}-py${{ matrix.python-version-nd }}.yml
- name: echo conda config
run: |
conda info
conda list
conda config --show-sources
conda config --show
- name: Build
run: |
pip install -U pip
pip install -U setuptools
python -m pip install .[test]
python setup.py build_ext --inplace
- name: Test with pytest
run: pytest -vs tests/ --cov causalml/
- name: echo conda env
run: |
conda env export