From 534a27c7f5d5c37fd385b2e13544fec2f352a0c8 Mon Sep 17 00:00:00 2001 From: YuvHayun Date: Tue, 2 Jul 2024 16:42:18 +0300 Subject: [PATCH 1/2] Add support for all xsoar mps in IN121 validation --- .../commands/common/hook_validations/integration.py | 8 ++++++-- .../validators/IN_validators/IN121_is_valid_fetch.py | 8 +++++++- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/demisto_sdk/commands/common/hook_validations/integration.py b/demisto_sdk/commands/common/hook_validations/integration.py index 26ec9ca09fe..0901747b6ed 100644 --- a/demisto_sdk/commands/common/hook_validations/integration.py +++ b/demisto_sdk/commands/common/hook_validations/integration.py @@ -1308,8 +1308,12 @@ def is_valid_fetch(self) -> bool: marketplaces = get_item_marketplaces( item_path=self.file_path, item_data=self.current_file ) - is_xsoar_marketplace = ( - not marketplaces or MarketplaceVersions.XSOAR.value in marketplaces + is_xsoar_marketplace = not marketplaces or any( + [ + MarketplaceVersions.XSOAR.value in marketplaces, + MarketplaceVersions.XSOAR_SAAS.value in marketplaces, + MarketplaceVersions.XSOAR_ON_PREM.value in marketplaces, + ] ) fetch_required_params = ( INCIDENT_FETCH_REQUIRED_PARAMS diff --git a/demisto_sdk/commands/validate/validators/IN_validators/IN121_is_valid_fetch.py b/demisto_sdk/commands/validate/validators/IN_validators/IN121_is_valid_fetch.py index e1f58f532e7..801520c3c83 100644 --- a/demisto_sdk/commands/validate/validators/IN_validators/IN121_is_valid_fetch.py +++ b/demisto_sdk/commands/validate/validators/IN_validators/IN121_is_valid_fetch.py @@ -74,7 +74,13 @@ def is_valid_fetch_integration( """ fetch_required_params = ( INCIDENT_FETCH_REQUIRED_PARAMS - if MarketplaceVersions.XSOAR in marketplaces + if any( + [ + MarketplaceVersions.XSOAR in marketplaces, + MarketplaceVersions.XSOAR_SAAS in marketplaces, + MarketplaceVersions.XSOAR_ON_PREM in marketplaces, + ] + ) else ALERT_FETCH_REQUIRED_PARAMS ) current_integration = {} From d7f4d37e37c0b908e703d40b2e544237ca3237ee Mon Sep 17 00:00:00 2001 From: YuvHayun Date: Tue, 2 Jul 2024 16:48:08 +0300 Subject: [PATCH 2/2] add changelog --- .changelog/4398.yml | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 .changelog/4398.yml diff --git a/.changelog/4398.yml b/.changelog/4398.yml new file mode 100644 index 00000000000..99bbd2c77e0 --- /dev/null +++ b/.changelog/4398.yml @@ -0,0 +1,4 @@ +changes: +- description: Fixed an issue where IN121 in the new validate flow and IN148 in the old validate flow failed when running on content items with XSOAR on prem and XSOAR SAAS Marketplaces. + type: fix +pr_number: 4398