GeezerVison is showing github.com — fix(ci): a newer push to a PR is no longer cancelled by the older pus… · pingdotgg/t3code@a326dea
File tree
Expand file treeCollapse file tree
Open diff view settings
Expand file treeCollapse file tree
Open diff view settings
Collapse file
Copy file name to clipboardExpand all lines: .github/workflows/pr-size.yml +7-3Lines changed: 7 additions & 3 deletions | Original file line number | Diff line number | Diff line change |
|---|
|
7 | 7 | permissions: |
8 | 8 | contents: read |
9 | 9 |
|
| 10 | +# Run-level, not job-level: runs join the group when their event arrives, so a newer push |
| 11 | +# always supersedes an older one. A job-level group is joined when the job starts, which |
| 12 | +# let an older run's slower job cancel the newer head's job and label from a stale diff. |
| 13 | +concurrency: |
| 14 | + group: pr-size-${{ github.event.pull_request.number }} |
| 15 | + cancel-in-progress: true |
| 16 | + |
10 | 17 | jobs: |
11 | 18 | prepare-config: |
12 | 19 | name: Prepare PR size config |
@@ -120,9 +127,6 @@ jobs: |
120 | 127 | contents: read |
121 | 128 | issues: read |
122 | 129 | pull-requests: write |
123 | | - concurrency: |
124 | | - group: pr-size-${{ github.event.pull_request.number }} |
125 | | - cancel-in-progress: true |
126 | 130 | steps: |
127 | 131 | # This pull_request_target job may fetch untrusted PR commits only as passive |
128 | 132 | # git data. Do not add dependency installs, build/test scripts, or cache |
|
Collapse file
Copy file name to clipboardExpand all lines: .github/workflows/pr-vouch.yml +11-3Lines changed: 11 additions & 3 deletions | Original file line number | Diff line number | Diff line change |
|---|
|
15 | 15 | permissions: |
16 | 16 | contents: read |
17 | 17 |
|
| 18 | +# Per-PR events supersede each other at the run level, in arrival order (a job-level group |
| 19 | +# is joined when the job starts, so an older run's slower job could cancel the newer one). |
| 20 | +# Other comments and pushes get a unique group so they never cancel a PR's run. |
| 21 | +concurrency: |
| 22 | + group: >- |
| 23 | + ${{ (github.event_name == 'pull_request_target' || |
| 24 | + (github.event_name == 'issue_comment' && contains(github.event.comment.body, '/recheck-vouch'))) |
| 25 | + && format('pr-vouch-run-{0}', github.event.pull_request.number || github.event.issue.number) |
| 26 | + || format('pr-vouch-run-{0}', github.run_id) }} |
| 27 | + cancel-in-progress: true |
| 28 | + |
18 | 29 | jobs: |
19 | 30 | collect-targets: |
20 | 31 | name: Collect PR targets |
|
74 | 85 | permissions: |
75 | 86 | contents: read |
76 | 87 | pull-requests: write |
77 | | - concurrency: |
78 | | - group: pr-vouch-${{ matrix.target.number }} |
79 | | - cancel-in-progress: true |
80 | 88 | strategy: |
81 | 89 | fail-fast: false |
82 | 90 | matrix: |
|