From 7694f7ec6f53a55679a50130c1b12b2735289213 Mon Sep 17 00:00:00 2001 From: Henrique Nakashima Date: Thu, 25 Jan 2018 23:43:53 +0000 Subject: Add timeout when downloading gold json. Short timeout for now as we don't yet rely on this json. Change-Id: I2dcbf714c04f39b120f2ad380dbd34e2569b8b78 Reviewed-on: https://pdfium-review.googlesource.com/24010 Reviewed-by: dsinclair Commit-Queue: Henrique Nakashima --- testing/tools/gold.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/testing/tools/gold.py b/testing/tools/gold.py index a8222378e8..89dfce1b81 100644 --- a/testing/tools/gold.py +++ b/testing/tools/gold.py @@ -68,7 +68,7 @@ class GoldBaseline(object): GOLD_BASELINE_URL = ('https://storage.googleapis.com/skia-infra-gm/' 'hash_files/gold-pdfium-baseline.json') try: - response = urllib2.urlopen(GOLD_BASELINE_URL) + response = urllib2.urlopen(GOLD_BASELINE_URL, timeout=2) json_data = response.read() except (urllib2.HTTPError, urllib2.URLError) as e: print ('Error: Unable to read skia gold json from %s: %s' -- cgit v1.2.3