From b99875c4c465d0d56ad3fa8aba67e7589c46c3d3 Mon Sep 17 00:00:00 2001 From: Adam Janovsky Date: Mon, 19 Apr 2021 11:05:51 +0200 Subject: n_threads in cve configurable --- sec_certs/cve.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sec_certs/cve.py b/sec_certs/cve.py index 8415728d..a8cc9742 100644 --- a/sec_certs/cve.py +++ b/sec_certs/cve.py @@ -139,7 +139,7 @@ class CVEDataset(ComplexSerializableType): logger.info(f'Identified {len(urls)} CVE files to fetch from nist.gov. Downloading them into {output_path}') with tempfile.TemporaryDirectory() as tmp_dir: outpaths = [Path(tmp_dir) / Path(x).name.rstrip('.zip') for x in urls] - responses = list(zip(*helpers.download_parallel(list(zip(urls, outpaths)), num_threads=8)))[1] + responses = list(zip(*helpers.download_parallel(list(zip(urls, outpaths)), num_threads=constants.N_THREADS)))[1] for o, u, r in zip(outpaths, urls, responses): if r == constants.RESPONSE_OK: -- cgit v1.3.1