Skip to content

release: start phylib 2.7.2 development (#67) #22

release: start phylib 2.7.2 development (#67)

release: start phylib 2.7.2 development (#67) #22

Workflow file for this run

name: CI
on:
push:
branches:
- master
pull_request:
workflow_dispatch:
permissions:
contents: read
concurrency:
group: ci-${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: Set up Python
uses: actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v6.1.0
with:
python-version: "3.12"
cache: pip
cache-dependency-path: requirements-dev.txt
- name: Install lint dependencies
run: python -m pip install flake8
- name: Run lint
run: python -m flake8 phylib
test:
name: ${{ matrix.scope }} (${{ matrix.os }}, Python ${{ matrix.python-version }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-latest
python-version: "3.10"
scope: Full tests
test-target: phylib
- os: ubuntu-latest
python-version: "3.11"
scope: Full tests
test-target: phylib
- os: ubuntu-latest
python-version: "3.12"
scope: Full tests
test-target: phylib
- os: macos-latest
python-version: "3.12"
scope: Full tests
test-target: phylib
- os: windows-latest
python-version: "3.12"
scope: Smoke tests
test-target: phylib/electrode phylib/stats phylib/utils
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v6.1.0
with:
python-version: ${{ matrix.python-version }}
cache: pip
cache-dependency-path: |
requirements.txt
requirements-dev.txt
- name: Install dependencies
run: |
python -m pip install --upgrade pip setuptools
python -m pip install -r requirements-dev.txt -e .
- name: Run tests
run: python -m pytest ${{ matrix.test-target }}
build:
name: Build package
runs-on: ubuntu-latest
needs: [lint, test]
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
- name: Set up Python
uses: actions/setup-python@83679a892e2d95755f2dac6acb0bfd1e9ac5d548 # v6.1.0
with:
python-version: "3.12"
cache: pip
cache-dependency-path: requirements.txt
- name: Build package
run: |
python -m pip install --upgrade build
python -m build
- name: Upload build artifacts
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: dist
path: dist/
if-no-files-found: error