Skip to content

Commit

Permalink
[ews-build] ValidateCommitMessage intermittently fails to access cont…
Browse files Browse the repository at this point in the history
…ributors.json

https://bugs.webkit.org/show_bug.cgi?id=275271
rdar://129016422

Reviewed by Aakash Jain.

Add retries to ValidateCommitMessage.

* Tools/CISupport/ews-build/steps.py:
(ValidateCommitMessage.run):

Canonical link: https://commits.webkit.org/279889@main
  • Loading branch information
briannafan committed Jun 10, 2024
1 parent 7748b63 commit ab4ce44
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions Tools/CISupport/ews-build/steps.py
Original file line number Diff line number Diff line change
Expand Up @@ -6564,9 +6564,16 @@ def run(self, BufferLogObserverClass=logobserver.BufferLogObserver):
defer.returnValue(rc)
return

self.contributors, errors = yield Contributors.load(use_network=True)
for error in errors:
self._addToLog('stdio', error)
retry_attempts = 3
for i in range(1, retry_attempts + 1):
self.contributors, errors = yield Contributors.load(use_network=True)
for error in errors:
self._addToLog('stdio', error)
self._addToLog('stdio', '\n')
if self.contributors:
break
if i < retry_attempts:
self._addToLog('stdio', f'Retrying, attempt {i + 1} of {retry_attempts}...\n')

reviewers, log_text = self.extract_reviewers(self.log_observer.getStdout())
log_text = log_text.rstrip()
Expand All @@ -6576,7 +6583,7 @@ def run(self, BufferLogObserverClass=logobserver.BufferLogObserver):
self.summary = 'ChangeLog modified, WebKit only allows commit messages'
rc = FAILURE
elif log_text:
self.summary = log_text
self.summary = log_text.split('\n')[0] # Display the first error if there are multiple
rc = FAILURE
elif rc == SUCCESS:
if reviewers and not self.contributors:
Expand Down

0 comments on commit ab4ce44

Please sign in to comment.