chore: rerun the notebook to check with the latest changes. #4
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: CI | |
on: | |
push: | |
branches: | |
- '**' | |
tags-ignore: | |
- '**' | |
pull_request: | |
branches: | |
- '**' | |
workflow_dispatch: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
test: | |
name: python ${{ matrix.python-version }}, ${{ matrix.os }} | |
runs-on: ${{ matrix.os }} | |
env: | |
REPO_NAME: ${{ github.event.repository.name }} | |
defaults: | |
run: | |
shell: bash -l {0} | |
strategy: | |
matrix: | |
python-version: [3.9, '3.12'] | |
os: [ubuntu-latest, macos-latest, windows-latest] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set environment variables | |
run: |- | |
echo "PYTHON_VERSION=${{ matrix.python-version }}" >> $GITHUB_ENV | |
- name: Setup micromamba | |
uses: mamba-org/setup-micromamba@v2 | |
env: | |
DATE: ${{ steps.date.outputs.time }} | |
with: | |
environment-file: ci/requirements/environment.yml | |
environment-name: ${{ env.REPO_NAME }}-tests | |
create-args: >- | |
python=${{ matrix.python-version }} | |
post-cleanup: all | |
cache-environment: true | |
cache-environment-key: ${{runner.os}}-${{runner.arch}}-py${{matrix.python-version}}-${{env.DATE}} | |
- name: Install error reporter | |
if: matrix.os == 'ubuntu-latest' && matrix.python-version == '3.12' | |
run: | | |
python -m pip install pytest-github-actions-annotate-failures | |
- name: Install the package | |
run: |- | |
python -m pip install --no-deps . | |
- name: Run pytest | |
run: |- | |
pytest | |
- name: Upload coverage reports to Codecov | |
uses: codecov/codecov-action@v5 | |
with: | |
token: ${{ secrets.CODECOV_TOKEN }} | |
slug: ${{ github.event.repository.owner.login }}/${{ github.event.repository.name }} |