Bump scipy from 1.14.1 to 1.15.0 #866
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: Python package | |
on: | |
push: | |
branches: master | |
tags: v* | |
pull_request: [] | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: astral-sh/ruff-action@v3 | |
- run: ruff format | |
build: | |
needs: lint | |
runs-on: ubuntu-latest | |
strategy: | |
max-parallel: 4 | |
matrix: | |
python-version: | |
- "3.10" | |
- "3.11" | |
- "3.12" | |
- "3.13" | |
steps: | |
- name: Install apt packages | |
run: | | |
sudo apt update | |
sudo apt install libopenblas-dev | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install dependencies | |
run: | | |
pipx install 'poetry>=2' | |
- name: Check tags | |
if: startsWith(github.event.ref, 'refs/tags') | |
id: tag | |
run: | | |
# double echo to strip whitespace | |
gitd=$(echo $(git describe --tags)) | |
echo "tag=$gitd"' >> $GITHUB_OUTPUT | |
poetryv=$(echo v$(poetry version | cut -d ' ' -f2)) | |
echo $gitd | |
echo $poetryv | |
- name: Install package for testing | |
run: poetry install -v --all-extras | |
- name: Test with pytest | |
run: poetry run pytest --script-launch-mode=subprocess | |
- name: Reinstall package for production | |
run: | | |
poetry env list --full-path | xargs rm -rf | |
poetry install -v | |
- name: Build distribution package | |
id: build | |
run: | | |
set -eux | |
# Torture git-describe into an acceptable Python version format | |
new_tag=$(git describe --tags | cut -c2- | sed 's/-/+/' | sed 's/-/./g') | |
echo $new_tag | |
echo "version=$new_tag" >> $GITHUB_OUTPUT | |
poetry version $new_tag | |
poetry build | |
- uses: actions/upload-artifact@v4 | |
if: matrix.python-version == '3.13' | |
with: | |
name: ${{ steps.build.outputs.version }} | |
path: dist | |
publish-to-pypi: | |
name: Publish distribution to PyPI | |
if: startsWith(github.event.ref, 'refs/tags') | |
needs: | |
- build | |
runs-on: ubuntu-latest | |
environment: | |
name: pypi | |
url: https://pypi.org/p/tact | |
permissions: | |
id-token: write | |
steps: | |
- uses: actions/download-artifact@v4 | |
with: | |
name: ${{ steps.build.outputs.version }} | |
path: dist/ | |
- uses: pypa/gh-action-pypi-publish@release/v1 |