diff options
author | Munyoki Kilyungi | 2023-11-06 14:51:04 +0300 |
---|---|---|
committer | BonfaceKilz | 2023-11-06 14:52:44 +0300 |
commit | b6354e7b892c4fc9f9f940856fa4d19fa192533a (patch) | |
tree | 868c27d04d863b43ebce4a7090040f1dfb94d95f /test | |
parent | 9233c4477f69819df59cb1ca639aef47ad36ef20 (diff) | |
download | genenetwork2-b6354e7b892c4fc9f9f940856fa4d19fa192533a.tar.gz |
Get full trace of SSL error and reduce number of retries in MR.
* test/requests/test-website.py (host_is_online): Reduce tries from 10
to 5. Also, print out the full error---useful for CD debugging.
Signed-off-by: Munyoki Kilyungi <me@bonfacemunyoki.com>
Diffstat (limited to 'test')
-rwxr-xr-x | test/requests/test-website.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/test/requests/test-website.py b/test/requests/test-website.py index fe197018..91bcb12d 100755 --- a/test/requests/test-website.py +++ b/test/requests/test-website.py @@ -22,13 +22,14 @@ print("Mechanical Rob firing up...") def host_is_online(host): import time import requests - for count in range(1, 10): + for count in range(1, 5): try: time.sleep(count) requests.get(host, verify=False) return True except Exception as cre: print(f"Retrying in {count + 1} seconds ...") + print(f"Error: {cre}") return False |