Skip to content

Merge branch 'main' into build/medcat/CU-869ddh1jv-fix-test-model-upload #15

Merge branch 'main' into build/medcat/CU-869ddh1jv-fix-test-model-upload

Merge branch 'main' into build/medcat/CU-869ddh1jv-fix-test-model-upload #15

name: medcat-den release-build

Check failure on line 1 in .github/workflows/medcat-den_release.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/medcat-den_release.yml

Invalid workflow file

(Line: 57, Col: 5): Unexpected value 'uses', (Line: 58, Col: 5): Unexpected value 'with'
on:
push:
tags:
- 'medcat-den/v*.*.*'
permissions:
id-token: write
defaults:
run:
working-directory: ./medcat-den
jobs:
test-and-publish-to-PyPI:
runs-on: ubuntu-latest
steps:
- name: Checkout main
uses: actions/checkout@v6
- name: Release Tag
# If GITHUB_REF=refs/tags/medcat-den/v0.1.2, this returns v0.1.2. Note it's including the "v" though it probably shouldnt
run: echo "RELEASE_VERSION=${GITHUB_REF##refs/*/}" >> $GITHUB_ENV
- name: Set up Python
uses: actions/setup-python@v6
with:
python-version: '3.10'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install --upgrade build
- name: Install client package in development mode
run: |
pip install -e ".[dev]"
- name: Test
run: |
pytest tests
- name: Build client package
run: |
python -m build
- name: Publish production distribution to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
packages_dir: medcat-den/dist
# test-time models for download
upload-test-models:
runs-on: ubuntu-latest
needs: test-and-publish-to-PyPI
uses: ./.github/workflows/upload-test-models.yml
with:
tag: ${{ github.ref_name }}