Skip to content

Commit 5af984a

Browse files
Add compatibility with upload-artifact v4
Names of artifacts need to be distinct now
1 parent 931e5c9 commit 5af984a

File tree

2 files changed

+13
-4
lines changed

2 files changed

+13
-4
lines changed

.github/workflows/primer_run_main.yaml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,8 +82,9 @@ jobs:
8282
run: |
8383
. venv/bin/activate
8484
python tests/primer/__main__.py prepare --clone
85-
- name: Upload output diff
85+
- name: Upload commit string
8686
uses: actions/upload-artifact@v4.0.0
87+
if: matrix.batchIdx == 0
8788
with:
8889
name: primer_commitstring
8990
path:
@@ -105,7 +106,9 @@ jobs:
105106
- name: Upload output
106107
uses: actions/upload-artifact@v4.0.0
107108
with:
108-
name: primer_output
109+
name:
110+
primer_output_main_${{ steps.python.outputs.python-version }}_batch${{
111+
matrix.batchIdx }}
109112
path: >-
110113
tests/.pylint_primer_tests/output_${{ steps.python.outputs.python-version
111114
}}_main_batch${{ matrix.batchIdx }}.txt

.github/workflows/primer_run_pr.yaml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -174,14 +174,18 @@ jobs:
174174
- name: Upload output of PR
175175
uses: actions/upload-artifact@v4.0.0
176176
with:
177-
name: primer_output_pr
177+
name:
178+
primer_output_pr_${{ steps.python.outputs.python-version }}_batch${{
179+
matrix.batchIdx }}
178180
path:
179181
tests/.pylint_primer_tests/output_${{ steps.python.outputs.python-version
180182
}}_pr_batch${{ matrix.batchIdx }}.txt
181183
- name: Upload output of 'main'
182184
uses: actions/upload-artifact@v4.0.0
183185
with:
184-
name: primer_output_main
186+
name:
187+
primer_output_main_${{ steps.python.outputs.python-version }}_batch${{
188+
matrix.batchIdx }}
185189
path:
186190
output_${{ steps.python.outputs.python-version }}_main_batch${{
187191
matrix.batchIdx }}.txt
@@ -191,6 +195,8 @@ jobs:
191195
run: |
192196
echo ${{ github.event.pull_request.number }} | tee pr_number.txt
193197
- name: Upload PR number
198+
if:
199+
startsWith(steps.python.outputs.python-version, '3.8') && matrix.batchIdx == 0
194200
uses: actions/upload-artifact@v4.0.0
195201
with:
196202
name: pr_number

0 commit comments

Comments
 (0)