From 17ea4feece70873a91f8b5083711f188e148f155 Mon Sep 17 00:00:00 2001 From: PRAteek-singHWY Date: Sat, 17 Jan 2026 15:07:24 +0530 Subject: [PATCH] fix(parsers): remove duplicated ID from PCI DSS section name (#328) --- .../utils/external_project_parsers/parsers/pci_dss.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/application/utils/external_project_parsers/parsers/pci_dss.py b/application/utils/external_project_parsers/parsers/pci_dss.py index 8a451d41f..53611577b 100644 --- a/application/utils/external_project_parsers/parsers/pci_dss.py +++ b/application/utils/external_project_parsers/parsers/pci_dss.py @@ -57,6 +57,13 @@ def __parse( ).strip(), version=version, ) + # Fix for Issue #328: Remove ID from Section Name if duplicated + if pci_control.section.startswith(pci_control.sectionID): + # Remove the ID and any leading whitespace/punctuation left over + pci_control.section = pci_control.section[ + len(pci_control.sectionID) : + ].strip() + existing = cache.get_nodes( name=pci_control.name, section=pci_control.section,