We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 663ffed commit b4e6ed8Copy full SHA for b4e6ed8
browsermobproxy/server.py
@@ -102,6 +102,8 @@ def start(self, options=None):
102
options = {
103
'log_path': os.getcwd(),
104
'log_file': 'server.log',
105
+ 'retry_sleep': 0.5,
106
+ 'retry_count': 60,
107
}
108
log_path = options.get('log_path')
109
log_file = options.get('log_file')
@@ -120,9 +122,9 @@ def start(self, options=None):
120
122
"for a helpful error message.".format(self.log_file))
121
123
124
raise Exception(message)
- time.sleep(0.5)
125
+ time.sleep(options.get('retry_sleep'))
126
count += 1
- if count == 60:
127
+ if count == options.get('retry_count'):
128
self.stop()
129
raise Exception("Can't connect to Browsermob-Proxy")
130
0 commit comments