Skip to content

Commit

Permalink
chore: cache pip in setup-python (#3436)
Browse files Browse the repository at this point in the history
installing dependencies takes about 1min per job. pip caching should
speed it up. note that in theory, this caches "correctly" in that it
doesn't cache the dependency graph or install directories, just the
wheels. so if upstream packages are updated, they should get
reinstalled.
  • Loading branch information
charles-cooper authored May 19, 2023
1 parent 32c9a3d commit 11e1ae9
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 1 deletion.
2 changes: 2 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ jobs:
uses: actions/setup-python@v4
with:
python-version: "3.11"
cache: "pip"

- name: Generate Binary
run: >-
Expand Down Expand Up @@ -61,6 +62,7 @@ jobs:
uses: actions/setup-python@v4
with:
python-version: "3.11"
cache: "pip"

- name: Generate Binary
run: >-
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/era-tester.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ jobs:
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version[0] }}
cache: "pip"

- name: Get cache
id: get-cache
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
- name: Python
uses: actions/setup-python@v4
with:
python-version: '3.x'
python-version: "3.11"

- name: Install dependencies
run: |
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ jobs:
uses: actions/setup-python@v4
with:
python-version: "3.11"
cache: "pip"

- name: Install Dependencies
run: pip install .[lint]
Expand All @@ -46,6 +47,7 @@ jobs:
uses: actions/setup-python@v4
with:
python-version: "3.11"
cache: "pip"

- name: Install Tox
run: pip install tox
Expand All @@ -63,6 +65,7 @@ jobs:
uses: actions/setup-python@v4
with:
python-version: "3.11"
cache: "pip"

- name: Install Tox
run: pip install tox
Expand All @@ -88,6 +91,7 @@ jobs:
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version[0] }}
cache: "pip"

- name: Install Tox
run: pip install tox
Expand Down Expand Up @@ -130,6 +134,7 @@ jobs:
uses: actions/setup-python@v4
with:
python-version: "3.11"
cache: "pip"

- name: Install Tox
run: pip install tox
Expand Down Expand Up @@ -171,6 +176,7 @@ jobs:
uses: actions/setup-python@v4
with:
python-version: "3.11"
cache: "pip"

- name: Install Tox
run: pip install tox
Expand Down

0 comments on commit 11e1ae9

Please sign in to comment.