Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(911)

Unified Diff: scm.py

Issue 1812001: Standardize automatic retry and add a 15 seconds sleep to increase the chances of success (Closed)
Patch Set: Created 10 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « gclient_scm.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: scm.py
diff --git a/scm.py b/scm.py
index cbb44f26781a822bb6897d6754070b394d0c3ab2..6693fad7dfd528bf45e6edc57856f475828efde9 100644
--- a/scm.py
+++ b/scm.py
@@ -11,6 +11,7 @@ import shutil
import subprocess
import sys
import tempfile
+import time
import xml.dom.minidom
import gclient_utils
@@ -381,7 +382,7 @@ class SVN(object):
}[args[0]]
compiled_pattern = re.compile(pattern)
# Place an upper limit.
- for _ in range(1, 10):
+ for _ in range(10):
previous_list_len = len(file_list)
failure = []
@@ -405,6 +406,8 @@ class SVN(object):
if args[0] == 'checkout':
# An aborted checkout is now an update.
args = ['update'] + args[1:]
+ print "Sleeping 15 seconds and retrying...."
+ time.sleep(15)
continue
# No progress was made or an unknown error we aren't sure, bail out.
raise
« no previous file with comments | « gclient_scm.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698