Skip to content

Commit

Permalink
💚 Fix GitHub Actions Poetry setup (#21)
Browse files Browse the repository at this point in the history
  • Loading branch information
tiangolo authored Nov 23, 2020
1 parent 2b87140 commit c35cc3d
Showing 1 changed file with 6 additions and 7 deletions.
13 changes: 6 additions & 7 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,10 @@ jobs:
run: echo ::set-output name=version::$(python -c "import sys; print('-'.join(str(v) for v in sys.version_info))")
- name: Install poetry
run: |
curl -fsS -o get-poetry.py https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py
python get-poetry.py -y
echo "::set-env name=PATH::$HOME/.poetry/bin:$PATH"
python -m pip install --upgrade pip
python -m pip install poetry
- name: Configure poetry
run: poetry config virtualenvs.in-project true
run: python -m poetry config virtualenvs.in-project true
- name: Set up cache
uses: actions/cache@v1
id: cache
Expand All @@ -37,10 +36,10 @@ jobs:
key: venv-${{ runner.os }}-${{ steps.full-python-version.outputs.version }}-${{ hashFiles('**/poetry.lock') }}
- name: Ensure cache is healthy
if: steps.cache.outputs.cache-hit == 'true'
run: poetry run pip --version >/dev/null 2>&1 || rm -rf .venv
run: python -m poetry run pip --version >/dev/null 2>&1 || rm -rf .venv
- name: Install Dependencies
run: poetry install
run: python -m poetry install
- name: Test
run: poetry run bash scripts/test.sh
run: python -m poetry run bash scripts/test.sh
- name: Upload coverage
uses: codecov/codecov-action@v1

0 comments on commit c35cc3d

Please sign in to comment.