Skip to content

Commit

Permalink
use cache-pip action (#17756)
Browse files Browse the repository at this point in the history
* use `cache-pip` action

* and other places

* empty

* `cache-pip@main`

* Update build-windows-installer.yml

* Update test-single.yml

* Update benchmarks.yml
  • Loading branch information
altendky authored Mar 22, 2024
1 parent 4913819 commit b08713f
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 44 deletions.
16 changes: 1 addition & 15 deletions .github/workflows/benchmarks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -74,21 +74,7 @@ jobs:
with:
fetch-depth: 0

- name: Get pip cache dir
id: pip-cache
shell: bash
run: |
# this is a workaround until https://github.com/Chia-Network/actions/pull/157 is ready
chown -R "$(whoami):$(whoami)" "${HOME}"
echo "dir=$(pip cache dir)" >> "$GITHUB_OUTPUT"
- name: Cache pip
uses: actions/cache@v4
with:
path: ${{ steps.pip-cache.outputs.dir }}
key: ${{ runner.os }}-pip-${{ hashFiles('**/setup.py') }}
restore-keys: |
${{ runner.os }}-pip-
- uses: chia-network/actions/cache-pip@main

- name: Checkout test blocks and plots
uses: actions/checkout@v4
Expand Down
14 changes: 1 addition & 13 deletions .github/workflows/build-windows-installer.yml
Original file line number Diff line number Diff line change
Expand Up @@ -92,19 +92,7 @@ jobs:
restore-keys: |
${{ runner.os }}-node-
- name: Get pip cache dir
id: pip-cache
shell: bash
run: |
echo "dir=$(pip cache dir)" >> "$GITHUB_OUTPUT"
- name: Cache pip
uses: actions/cache@v4
with:
path: ${{ steps.pip-cache.outputs.dir }}
key: ${{ runner.os }}-pip-${{ hashFiles('**/setup.py') }}
restore-keys: |
${{ runner.os }}-pip-
- uses: chia-network/actions/cache-pip@main

- uses: Chia-Network/actions/setup-python@main
name: Install Python ${{ matrix.python-version }}
Expand Down
17 changes: 1 addition & 16 deletions .github/workflows/test-single.yml
Original file line number Diff line number Diff line change
Expand Up @@ -162,22 +162,7 @@ jobs:
restore-keys: |
${{ runner.os }}-node-
- name: Get pip cache dir
id: pip-cache
shell: bash
run: |
echo "dir=$(pip cache dir)" >> "$GITHUB_OUTPUT"
- name: Cache pip
uses: actions/cache@v4
env:
SEGMENT_DOWNLOAD_TIMEOUT_MIN: 1
with:
# Note that new runners may break this https://github.com/actions/cache/issues/292
path: ${{ steps.pip-cache.outputs.dir }}
key: ${{ runner.os }}-pip-${{ hashFiles('**/setup.py') }}
restore-keys: |
${{ runner.os }}-pip-
- uses: chia-network/actions/cache-pip@main

- name: Cache test blocks and plots
if: matrix.configuration.checkout_blocks_and_plots
Expand Down

0 comments on commit b08713f

Please sign in to comment.