Commit 43eb220a authored by achuith@chromium.org's avatar achuith@chromium.org

Add retries so new tab is created for sure.

BUG=331940, 334726
TEST=manual
NOTRY=True

Review URL: https://codereview.chromium.org/135843005

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@245446 0039d316-1c4b-4281-b951-d872f2087c98
parent 06cbc31b
......@@ -430,13 +430,19 @@ class CrOSBrowserBackend(chrome_browser_backend.ChromeBrowserBackend):
util.WaitFor(self._StartupWindow, 20).Close()
else:
# Workaround for crbug.com/329271, crbug.com/334726.
try:
# Open a new window/tab.
tab = self.tab_list_backend.New(timeout=10)
tab.Navigate('about:blank', timeout=10)
except (exceptions.TabCrashException, util.TimeoutException):
logging.warn('TabCrashException in new tab creation/navigation')
retries = 3
while not len(self.tab_list_backend):
try:
# Open a new window/tab.
tab = self.tab_list_backend.New(timeout=30)
tab.Navigate('about:blank', timeout=10)
except (exceptions.TabCrashException, util.TimeoutException):
retries -= 1
logging.warn('TabCrashException/TimeoutException in '
'new tab creation/navigation, '
'remaining retries %d' % retries)
if not retries:
raise
class SSHForwarder(object):
def __init__(self, cri, forwarding_flag, *port_pairs):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment