Skip to content

Commit 36432b7

Browse files
authored
GA: simplify pip caching (#1589)
1 parent a33b446 commit 36432b7

File tree

2 files changed

+20
-28
lines changed

2 files changed

+20
-28
lines changed

.github/workflows/ci-tests.yml

Lines changed: 10 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -50,12 +50,10 @@ jobs:
5050
uses: actions/setup-python@v2
5151
with:
5252
python-version: ${{ env.py-semver }}
53-
54-
- name: Cache for pip
55-
uses: actions/cache@v2
56-
with:
57-
path: ~/.cache/pip
58-
key: ${{ runner.os }}-pip-${{ matrix.step }}-${{ hashFiles('requirements.txt', 'tox.ini') }}
53+
cache: pip
54+
cache-dependency-path: |
55+
requirements.txt
56+
tox.ini
5957
6058
- name: Upgrade setuptools and install tox
6159
run: |
@@ -100,12 +98,7 @@ jobs:
10098
uses: actions/setup-python@v2
10199
with:
102100
python-version: ${{ env.py-semver }}
103-
104-
- name: Cache for pip
105-
uses: actions/cache@v2
106-
with:
107-
path: ~/.cache/pip
108-
key: ${{ runner.os }}-pip-${{ matrix.step }}-${{ hashFiles('requirements.txt') }}
101+
cache: pip
109102

110103
- name: Upgrade setuptools and install tox
111104
run: |
@@ -141,12 +134,7 @@ jobs:
141134
uses: actions/setup-python@v2
142135
with:
143136
python-version: 3.9
144-
145-
- name: Cache for pip
146-
uses: actions/cache@v2
147-
with:
148-
path: ~/.cache/pip
149-
key: ${{ runner.os }}-conformance-${{ matrix.step }}-${{ hashFiles('requirements.txt') }}
137+
cache: pip
150138

151139
- name: Run CWL conformance tests ${{ matrix.cwl-version }}
152140
env:
@@ -172,16 +160,14 @@ jobs:
172160
uses: actions/setup-python@v2
173161
with:
174162
python-version: "3.10" # quoted, otherwise that turns into the number 3.1
163+
cache: pip
164+
cache-dependency-path: |
165+
requirements.txt
166+
test-requirements.txt
175167
176168
- name: Give the test runner user a name to make provenance happy.
177169
run: sudo usermod -c 'CI Runner' $(whoami)
178170

179-
- name: Cache for pip
180-
uses: actions/cache@v2
181-
with:
182-
path: ~/.cache/pip
183-
key: ${{ runner.os }}-pip-release-${{ hashFiles('requirements.txt', 'test-requirements.txt') }}
184-
185171
- name: Install packages
186172
run: |
187173
pip install -U pip setuptools wheel

.mergify.yml

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,19 @@
1+
queue_rules:
2+
- name: default
3+
conditions:
4+
- -draft # not a draft
5+
- base=main
6+
17
pull_request_rules:
28
- name: Automatic merge on approval and when when GitHub branch protection passes on main
39
conditions:
410
- "#approved-reviews-by>=1"
511
- -draft
612
- base=main
713
actions:
8-
merge:
14+
queue:
915
method: merge
10-
strict: smart+fasttrack
16+
name: default
1117

1218
pull_request_rules:
1319
- name: Automatic merge for leadership team members when there are no reviewers and the label is "ready"
@@ -19,6 +25,6 @@ pull_request_rules:
1925
- author=@leadership
2026
- label=ready
2127
actions:
22-
merge:
28+
queue:
2329
method: merge
24-
strict: smart+fasttrack
30+
name: default

0 commit comments

Comments
 (0)