Merge branch '105-bug-confidence-int' into 'release' #843
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: Pandora plugin libSGM CI | |
on: | |
push: | |
schedule: | |
- cron: 0 2 * * * | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python 3.x | |
uses: actions/setup-python@v2 | |
with: | |
python-version: "3.8" | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip freeze | |
- name: Install Pandora plugin libSGM | |
run: | | |
pip install .[dev] | |
pip freeze | |
- name: Clone Pandora submodule | |
run: | | |
mkdir submodule | |
cd submodule | |
pandora_version=$(pip freeze | grep pandora | sed -n '1 p') | |
pandora_version=${pandora_version##*=} | |
echo $pandora_version | |
git clone https://github.com/cnes/pandora --branch ${pandora_version} --depth 1 | |
- name: Test with pytest | |
run: | | |
pytest --junitxml=pytest-report.xml --cov-config=.coveragerc --cov-report xml --cov | |
- name: Test with pytest pandora's notebooks | |
run: | | |
cd submodule/pandora | |
python -m pip install --upgrade pip meson-python meson ninja setuptools_scm setuptools wheel pybind11 | |
pip install --no-build-isolation --editable .[dev,notebook] | |
hash -r | |
pytest -m notebook_tests | |
cd ../.. | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v1 | |
- name: Create source distrubition | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') | |
run: | | |
pip install build | |
python -m build | |
- name: Publish package on pypi | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags') | |
uses: pypa/gh-action-pypi-publish@release/v1 |