Bump version: 5.0.14 → 5.0.15 #112
Workflow file for this run
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: Build | |
on: | |
push: | |
branches: [main] | |
tags: ['v*'] | |
pull_request: | |
branches: [main] | |
workflow_dispatch: | |
env: | |
LATEST_PY_VERSION: '3.10' | |
PYTEST_VERBOSE: 'true' | |
jobs: | |
# Run tests for each supported python version | |
test: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: [3.8, 3.9, "3.10"] | |
fail-fast: false | |
steps: | |
# Set up python + poetry | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- uses: snok/install-poetry@v1 | |
with: | |
virtualenvs-in-project: true | |
# Cache packages per python version, and reuse until lockfile changes | |
- name: Cache python packages | |
id: cache | |
uses: actions/cache@v3 | |
with: | |
path: .venv | |
key: venv-${{ matrix.python-version }}-latest-${{ hashFiles('poetry.lock') }} | |
restore-keys: venv-${{ matrix.python-version }}-latest- | |
- name: Install dependencies | |
if: steps.cache.outputs.cache-hit != 'true' | |
run: poetry install -v && poetry run pip install pandas | |
# Run tests with coverage report | |
- name: Run tests | |
run: | | |
source $VENV | |
nox -e cov -- xml | |
env: | |
PATENT_CLIENT_BASE_DIR: ./${{ matrix.python-version }} | |
# Latest python version: send coverage report to codecov | |
- name: "Upload coverage report to Codecov" | |
if: ${{ matrix.python-version == env.LATEST_PY_VERSION }} | |
uses: codecov/codecov-action@v3 | |
# Run code analysis checks via pre-commit hooks | |
analyze: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: ${{ env.LATEST_PY_VERSION }} | |
- name: Run style checks & linting | |
uses: pre-commit/[email protected] |