mirror of
https://github.com/flatcar/scripts.git
synced 2026-05-04 19:56:32 +02:00
Check value in except
This commit is contained in:
parent
01c62e5da6
commit
4e85f966a4
@ -136,8 +136,9 @@ def RevGitPushWithRetry(retries=5):
|
||||
cros_build_lib.RunCommand('git push', shell=True)
|
||||
break
|
||||
except cros_build_lib.RunCommandError:
|
||||
print 'Error pushing changes trying again (%s/%s)' % (retry, retries)
|
||||
time.sleep(5*retry)
|
||||
if retry < retries:
|
||||
print 'Error pushing changes trying again (%s/%s)' % (retry, retries)
|
||||
time.sleep(5*retry)
|
||||
else:
|
||||
raise GitPushFailed('Failed to push change after %s retries' % retries)
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user