Skip to content

Commit

Permalink
ci: Change how poetry deps are cached (#310)
Browse files Browse the repository at this point in the history
  • Loading branch information
edgarrmondragon authored Sep 20, 2024
1 parent ce83dc7 commit 9372ab3
Showing 1 changed file with 5 additions and 10 deletions.
15 changes: 5 additions & 10 deletions .github/workflows/test_tap.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,27 +57,22 @@ jobs:
# file in the cache. See issue #119
key: api-cache-v4-${{ steps.get-date.outputs.date }}

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install Poetry
uses: snok/install-poetry@v1
with:
# Version of Poetry to use
version: 1.8.3
virtualenvs-create: true
virtualenvs-in-project: true
- name: Load cached venv
id: cached-poetry-dependencies
uses: actions/cache@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
path: .venv
key: venv-4-${{ runner.os }}-${{ hashFiles('**/poetry.lock') }}-${{ matrix.python-version }}
python-version: ${{ matrix.python-version }}
cache: poetry
- name: Install dependencies
run: |
poetry env use ${{ matrix.python-version }}
poetry install
if: steps.cached-poetry-dependencies.outputs.cache-hit != 'true'
- name: Test with pytest
id: test_pytest
continue-on-error: true
Expand Down

0 comments on commit 9372ab3

Please sign in to comment.