diff --git a/server/fetch_historical_bviews.py b/server/fetch_historical_bviews.py index 0bd6bbc..09ed00c 100755 --- a/server/fetch_historical_bviews.py +++ b/server/fetch_historical_bviews.py @@ -73,7 +73,10 @@ def downloadURL(url, filename): """ path_temp_bviewfile = os.path.join(c.raw_data, c.bview_dir, 'tmp', filename) path_bviewfile = os.path.join(c.raw_data, c.bview_dir, filename) - f = urllib.urlopen(url) + try: + f = urllib.urlopen(url) + except: + return False if f.getcode() != 200: publisher.warning('{} unavailable, code: {}'.format(url, f.getcode())) return False