From d87fad328991f82053aa872bef5ce1c013746195 Mon Sep 17 00:00:00 2001 From: Matthew Feickert Date: Mon, 6 May 2024 22:21:31 -0500 Subject: [PATCH] ci: Add lower bound requirements tests * Use 'uv pip install --upgrade --resolution lowest-direct' to automatically evaluate if the lower bounds of the dependencies specified are correct. --- .../workflows/lower-bound-requirements.yml | 37 +++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 .github/workflows/lower-bound-requirements.yml diff --git a/.github/workflows/lower-bound-requirements.yml b/.github/workflows/lower-bound-requirements.yml new file mode 100644 index 0000000..4caab06 --- /dev/null +++ b/.github/workflows/lower-bound-requirements.yml @@ -0,0 +1,37 @@ +name: Minimum supported dependencies + +on: + # Run weekly at 1:23 UTC + schedule: + - cron: '23 1 * * 0' + workflow_dispatch: + +jobs: + test: + + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [ubuntu-latest] + # minimum supported Python + python-version: ['3.9'] + + steps: + - uses: actions/checkout@v4 + + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v5 + with: + python-version: ${{ matrix.python-version }} + + - name: Install dependencies and force lowest bound + run: | + python -m pip install uv + uv pip install --system --upgrade ".[test]" + uv pip install --system --upgrade --resolution lowest-direct . + + - name: List installed Python packages + run: uv pip list --system + + - name: Test with pytest + run: pytest tests/