Change-Id: I9bba50281bfe65f62a1cfab76364d834dc10d80c
Signed-off-by: Tibor Frank <tifrank@cisco.com>
from os import rename, mkdir
from os.path import join
from os import rename, mkdir
from os.path import join
-from http.client import responses, IncompleteRead
+from http.client import responses, HTTPException
from zipfile import ZipFile, is_zipfile, BadZipfile
import requests
from zipfile import ZipFile, is_zipfile, BadZipfile
import requests
from requests.exceptions import RequestException
from requests import codes
from requests.exceptions import RequestException
from requests import codes
+from urllib3.exceptions import HTTPError
+
from pal_errors import PresentationError
from pal_errors import PresentationError
session.mount(u"https://", adapter)
return session
session.mount(u"https://", adapter)
return session
while repeat:
repeat -= 1
while repeat:
repeat -= 1
session = None
try:
logging.info(f" Connecting to {url} ...")
session = None
try:
logging.info(f" Connecting to {url} ...")
success = True
repeat = 0
success = True
repeat = 0
- except IncompleteRead as err:
+ except (HTTPException, HTTPError) as err:
logging.error(f"Connection broken:\n{repr(err)}")
except RequestException as err:
logging.error(f"HTTP Request exception:\n{repr(err)}")
logging.error(f"Connection broken:\n{repr(err)}")
except RequestException as err:
logging.error(f"HTTP Request exception:\n{repr(err)}")
logging.info(f"Trying to download {url}")
arch = bool(spec.configuration.get(u"archive-inputs", True))
logging.info(f"Trying to download {url}")
arch = bool(spec.configuration.get(u"archive-inputs", True))
- success, downloaded_name = _download_file(url, new_name, arch=arch)
+ success, downloaded_name = _download_file(
+ url, new_name, arch=arch, verify=True, repeat=3
+ )
plotly==4.1.1
PTable==0.9.2
hdrhistogram==0.6.1
plotly==4.1.1
PTable==0.9.2
hdrhistogram==0.6.1