Skip to content

Build

Build #3340

Workflow file for this run

name: Build
on:
push:
pull_request:
schedule:
# Run at the end of every day
- cron: "0 0 * * *"
jobs:
build:
# Scheduled runs only on the origin org
if: (github.event_name == 'schedule' && github.repository_owner == 'sgkit-dev') || (github.event_name != 'schedule')
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11"]
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt -r requirements-dev.txt
- name: Run pre-commit
uses: pre-commit/[email protected]
- name: Test with pytest (numba jit disabled)
env:
NUMBA_DISABLE_JIT: 1
run: |
# avoid guvectorized functions #1194
pytest -v sgkit/tests/test_pedigree.py
- name: Test with pytest and coverage
run: |
pytest -v --cov=sgkit --cov-report=term-missing
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
test-zarr-version:
name: Test Zarr Python v3
# Scheduled runs only on the origin org
if: (github.event_name == 'schedule' && github.repository_owner == 'sgkit-dev') || (github.event_name != 'schedule')
runs-on: ubuntu-latest
strategy:
matrix:
zarr: ["==3.0.0b1"]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt -r requirements-dev.txt
- name: Install zarr${{ matrix.zarr }}
run: |
python -m pip install --pre 'zarr${{ matrix.zarr }}'
python -m pip uninstall -y bio2zarr # TODO: remove when bio2zarr supports Zarr Python 3
- name: Run tests
run: |
pytest