Skip to content

Commit 5a0eb96

Browse files
CI: PrAssignee.yml: Don't retry on 403 (#58555)
As noted in #58550 (comment) --------- Co-authored-by: Dilum Aluthge <[email protected]>
1 parent 965d007 commit 5a0eb96

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

.github/workflows/PrAssignee.yml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,11 @@ jobs:
3838
uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1
3939
with:
4040
retries: 5 # retry GitHub API requests up to 5 times, with exponential backoff
41-
retry-exempt-status-codes: "403,404"
42-
# In the above list:
43-
#
44-
# - 404 is in the list because we will always hit a 404 when the PR author is not
45-
# a committer. This 404 is normal and expected.
41+
retry-exempt-status-codes: 404
42+
# Don't retry 404 because we will hit a 404 when the PR author is a committer.
43+
# This 404 is normal and expected.
44+
# Do retry 400 and other 4xx errors because github sometimes (erroneously)
45+
# returns a 4xx error code due to server errors.
4646
script: |
4747
const oldPrAssignees = context.payload.pull_request.assignees
4848
.map(obj => obj.login)

0 commit comments

Comments
 (0)