From 3131d53741d6b74f3f856b4b6c129f591a4a1b22 Mon Sep 17 00:00:00 2001 From: Philip Germanov Date: Thu, 28 Aug 2025 15:12:30 +0300 Subject: [PATCH] feat: update error messages for Checkmarx One and npm scripts for clarity and multi-module support --- cmd/checkmarxOneExecuteScan_generated.go | 5 ----- cmd/npmExecuteScripts_generated.go | 2 +- resources/metadata/checkmarxOneExecuteScan.yaml | 3 --- resources/metadata/npmExecuteScripts.yaml | 2 +- 4 files changed, 2 insertions(+), 10 deletions(-) diff --git a/cmd/checkmarxOneExecuteScan_generated.go b/cmd/checkmarxOneExecuteScan_generated.go index d2f737dd1..fdf17f122 100644 --- a/cmd/checkmarxOneExecuteScan_generated.go +++ b/cmd/checkmarxOneExecuteScan_generated.go @@ -457,11 +457,6 @@ func checkmarxOneExecuteScanMetadata() config.StepData { Aliases: []config.Alias{}, Description: "checkmarxOne is the recommended tool for security scans of JavaScript, iOS, Swift and Ruby code.", Errors: []config.StepError{ - { - Pattern: "Checkmarx One scan failed with the following error.*Scan Failed", - Message: "Checkmarx One scan failed during execution. Check scan configuration and project settings.", - Category: "scan", - }, { Pattern: "project .* not compliant", Message: "Project failed compliance checks. Review security findings and fix issues to meet compliance requirements.", diff --git a/cmd/npmExecuteScripts_generated.go b/cmd/npmExecuteScripts_generated.go index 4afd0228d..26d2ddd59 100644 --- a/cmd/npmExecuteScripts_generated.go +++ b/cmd/npmExecuteScripts_generated.go @@ -330,7 +330,7 @@ func npmExecuteScriptsMetadata() config.StepData { }, { Pattern: "npm error code ENOENT.*package.json", - Message: "Package.json file not found. Ensure package.json exists in the correct directory.", + Message: "Package.json file not found. Ensure package.json exists in the correct directory. For multi-module projects, check if buildDescriptorList and buildDescriptorExcludeList are correct.", Category: "configuration", }, }, diff --git a/resources/metadata/checkmarxOneExecuteScan.yaml b/resources/metadata/checkmarxOneExecuteScan.yaml index 2d67da68b..f3b0ebc5d 100644 --- a/resources/metadata/checkmarxOneExecuteScan.yaml +++ b/resources/metadata/checkmarxOneExecuteScan.yaml @@ -2,9 +2,6 @@ metadata: name: checkmarxOneExecuteScan description: checkmarxOne is the recommended tool for security scans of JavaScript, iOS, Swift and Ruby code. errors: - - pattern: "Checkmarx One scan failed with the following error.*Scan Failed" - message: "Checkmarx One scan failed during execution. Check scan configuration and project settings." - category: "scan" - pattern: "project .* not compliant" message: "Project failed compliance checks. Review security findings and fix issues to meet compliance requirements." category: "compliance" diff --git a/resources/metadata/npmExecuteScripts.yaml b/resources/metadata/npmExecuteScripts.yaml index 889fa1654..0f0d984d1 100644 --- a/resources/metadata/npmExecuteScripts.yaml +++ b/resources/metadata/npmExecuteScripts.yaml @@ -29,7 +29,7 @@ metadata: message: "Package integrity check failed. Clear npm cache and retry installation." category: "dependency" - pattern: "npm error code ENOENT.*package.json" - message: "Package.json file not found. Ensure package.json exists in the correct directory." + message: "Package.json file not found. Ensure package.json exists in the correct directory. For multi-module projects, check if buildDescriptorList and buildDescriptorExcludeList are correct." category: "configuration" longDescription: > ### Lock file detection: