From 3388f885e220434a4c08476601ebc9853c89967a Mon Sep 17 00:00:00 2001 From: Shivam Sandbhor Date: Tue, 26 Oct 2021 18:40:42 +0530 Subject: [PATCH] Fix istio importer by skipping UI metadata files. (#570) Signed-off-by: Shivam Sandbhor --- vulnerabilities/importers/istio.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/vulnerabilities/importers/istio.py b/vulnerabilities/importers/istio.py index ca2717040..00a1dc32c 100644 --- a/vulnerabilities/importers/istio.py +++ b/vulnerabilities/importers/istio.py @@ -58,6 +58,11 @@ def updated_advisories(self) -> Set[Advisory]: files = self._added_files.union(self._updated_files) advisories = [] for f in files: + # Istio website has files with name starting with underscore, these contain metadata + # required for rendering the website. We're not interested in these. + # See also https://github.com/nexB/vulnerablecode/issues/563 + if f.endswith("_index.md"): + continue processed_data = self.process_file(f) if processed_data: advisories.extend(processed_data)