Skip to content
Snippets Groups Projects
Commit 97131c23 authored by Alan De Smet's avatar Alan De Smet
Browse files

download_for_scan returns list of final files

parent e90b2796
Branches
No related tags found
No related merge requests found
......@@ -781,6 +781,8 @@ class Downloader:
statistics
:type download_stats: None or csppfetch.DownloadStatistics
:return: list of strings to downloaded files
"""
base_urls = self.get_base_urls()
......@@ -817,7 +819,7 @@ class Downloader:
# since any exceptions will retry downloads
# when we already have the files!
pass
return True
return full_urls_to_file.values()
except Exception as e:
problems.append(f"Failed to download file set {description}: {str(e)}")
if attempt != retries:
......@@ -850,6 +852,8 @@ class Downloader:
download statistics
:type download_stats: None or csppfetch.DownloadStatistics
:return: list of strings to downloaded files
**timeout**, **retries**, and **retry_wait** are overriddeen by environment
variables ``package_env_id+TIMEOUT/RETRIES/RETRY_WAIT``
......@@ -860,7 +864,7 @@ class Downloader:
timeout = self.get_timeout(timeout)
retries = self.get_retries(retries)
retry_wait = self.get_retry_wait(retry_wait)
self.download_first_available(filesets, dst, timeout=timeout, retries=retries, retry_wait=retry_wait, do_download = do_download, download_stats = download_stats)
return self.download_first_available(filesets, dst, timeout=timeout, retries=retries, retry_wait=retry_wait, do_download = do_download, download_stats = download_stats)
def update_cache(self, dst, start_time=None, end_time=None, timeout=30, download_stats=None):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment