CI: setup-dependent pip cache (#16751)

* Setup-dependent pip cache

* Do not restore from old versions
This commit is contained in:
Joao Gante 2022-04-13 16:19:14 +01:00 committed by GitHub
parent ac43a40e6a
commit 0b8f697219
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 14 deletions

View file

@ -23,10 +23,7 @@ jobs:
id: cache
with:
path: ~/.cache/pip
key: v1-tests_model_like
restore-keys: |
v1-tests_model_like-${{ hashFiles('setup.py') }}
v1-tests_model_like
key: v1-tests_model_like-${{ hashFiles('setup.py') }}
- name: Install dependencies
run: |

View file

@ -29,10 +29,7 @@ jobs:
id: cache
with:
path: ~/.cache/pip
key: v1.2-tests_templates
restore-keys: |
v1.2-tests_templates-${{ hashFiles('setup.py') }}
v1.2-tests_templates
key: v1.2-tests_templates-${{ hashFiles('setup.py') }}
- name: Install dependencies
run: |

View file

@ -15,16 +15,13 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: Loading cache.
uses: actions/cache@v2
id: cache
with:
path: ~/.cache/pip
key: v1-metadata
restore-keys: |
v1-metadata-${{ hashFiles('setup.py') }}
v1-metadata
key: v1-metadata-${{ hashFiles('setup.py') }}
- name: Setup environment
run: |
@ -33,4 +30,3 @@ jobs:
- name: Update metadata
run: |
python utils/update_metadata.py --token ${{ secrets.SYLVAIN_HF_TOKEN }} --commit_sha ${{ github.sha }}