Skip to content

Disable Python 3.7 in CI due to Poetry installation errors #372

Disable Python 3.7 in CI due to Poetry installation errors

Disable Python 3.7 in CI due to Poetry installation errors #372

Workflow file for this run

on:
- push
- pull_request
name: Main
jobs:
pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.7'
- run: |
pip install poetry==1.2.2
poetry install
poetry run pre-commit run --all-files --show-diff-on-failure
test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version:
# As of 2024-06-26, Poetry has started failing to install on 3.7:
# `TypeError: Expected maxsize to be an integer or None`
- '3.8'
- '3.9'
- '3.10'
- '3.11'
poetry-version:
- '1.2.2'
- '1.3.2'
- '1.4.2'
- '1.5.1'
- '1.6.1'
- '1.7.1'
- '1.8.1'
include:
- python-version: '3.11'
poetry-version: 'git+https://github.com/radoering/poetry.git@pep621-support'
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- if: ${{ startsWith(matrix.poetry-version, 'git') }}
run: |
echo "USE_PEP621=1" >> $GITHUB_ENV
- run: |
pip install pipx
pipx install ${{ startsWith(matrix.poetry-version, 'git') && matrix.poetry-version || format('poetry=={0}', matrix.poetry-version) }}
pipx install invoke
poetry install --extras plugin
invoke test