From 6a1abfda86b2ed1230763a562ddca47cde0bbd01 Mon Sep 17 00:00:00 2001 From: Yuval Hayun <70104171+YuvHayun@users.noreply.github.com> Date: Mon, 16 Dec 2024 13:48:55 +0200 Subject: [PATCH] remove DS107, RM106, Rename RM116 (#4712) * remove DS107 * added changelog * removed RM106 * fix tests * changed the code of RM116 * fixes --- .changelog/4712.yml | 6 ++ demisto_sdk/commands/common/errors.py | 13 --- .../common/hook_validations/description.py | 82 ------------------- .../common/hook_validations/readme.py | 28 ------- .../commands/common/tests/description_test.py | 58 ------------- .../commands/common/tests/readme_test.py | 80 ------------------ .../validate/sdk_validation_config.toml | 6 +- .../validate/tests/DS_validators_test.py | 52 ------------ .../validate/tests/RM_validators_test.py | 57 +------------ .../validate/tests/old_validators_test.py | 21 ++--- ...07_is_description_contains_demisto_word.py | 52 ------------ .../RM106_is_contain_demisto_word.py | 58 ------------- ..._short.py => RM117_readme_not_to_short.py} | 4 +- 13 files changed, 19 insertions(+), 498 deletions(-) create mode 100644 .changelog/4712.yml delete mode 100644 demisto_sdk/commands/validate/validators/DS_validators/DS107_is_description_contains_demisto_word.py delete mode 100644 demisto_sdk/commands/validate/validators/RM_validators/RM106_is_contain_demisto_word.py rename demisto_sdk/commands/validate/validators/RM_validators/{RM116_readme_not_to_short.py => RM117_readme_not_to_short.py} (98%) diff --git a/.changelog/4712.yml b/.changelog/4712.yml new file mode 100644 index 00000000000..382b1a7e41a --- /dev/null +++ b/.changelog/4712.yml @@ -0,0 +1,6 @@ +changes: +- description: Removed support for DS107 and RM106 validations - ensure no 'demist'o word in description and readme files for both new & old validate. + type: breaking +- description: Changed the code of RM116 - Validate that the readme file is not to short to RM117 due to error code duplication. + type: breaking +pr_number: 4712 diff --git a/demisto_sdk/commands/common/errors.py b/demisto_sdk/commands/common/errors.py index d0feda55855..425a81e47ce 100644 --- a/demisto_sdk/commands/common/errors.py +++ b/demisto_sdk/commands/common/errors.py @@ -320,10 +320,6 @@ "code": "DS106", "related_field": "", }, - "description_contains_demisto_word": { - "code": "DS107", - "related_field": "detaileddescription", - }, "description_missing_dot_at_the_end": { "code": "DS108", "related_field": "description", @@ -1091,10 +1087,6 @@ "code": "RM105", "related_field": "readme", }, - "readme_contains_demisto_word": { - "code": "RM106", - "related_field": "readme", - }, "template_sentence_in_readme": { "code": "RM107", "related_field": "readme", @@ -2879,11 +2871,6 @@ def invalid_description_name(): "and that the integration_name is the same as the folder containing it." ) - @staticmethod - @error_code_decorator - def description_contains_demisto_word(line_nums, yml_or_file): - return f"Found the word 'Demisto' in the description content {yml_or_file} in lines: {line_nums}." - @staticmethod @error_code_decorator def description_missing_dot_at_the_end(details: str): diff --git a/demisto_sdk/commands/common/hook_validations/description.py b/demisto_sdk/commands/common/hook_validations/description.py index 21b3e25ab3f..a98b16467e9 100644 --- a/demisto_sdk/commands/common/hook_validations/description.py +++ b/demisto_sdk/commands/common/hook_validations/description.py @@ -56,7 +56,6 @@ def __init__( def is_valid_file(self): self.is_duplicate_description() - self.verify_demisto_in_description_content() # Validations that will run only on Markdown file if ( @@ -232,87 +231,6 @@ def is_valid_description_name(self): return True - @error_codes("DS104,DS107") - def verify_demisto_in_description_content(self): - """ - Checks if there are the word 'Demisto' in the description content. - - Return: - True if 'Demisto' does not exist in the description content, and False if it does. - """ - description_path = "" - yml_line_num = 0 - yml_or_file = "" - - # case 1 the file path is for an integration - if find_type(self.file_path) in [ - FileType.INTEGRATION, - FileType.BETA_INTEGRATION, - ]: - integration_path = self.file_path - is_unified_integration = self.data_dictionary.get("script", {}).get( - "script", "" - ) not in {"-", ""} - - if is_unified_integration: - description_content = self.data_dictionary.get( - "detaileddescription", "" - ) - yml_or_file = "in the yml file" - - # find in which line the description begins in the yml - with open(self.file_path) as f: - for line_n, line in enumerate(f.readlines()): - if "detaileddescription:" in line: - yml_line_num = line_n + 1 - - # if not found try and look for the description file path - else: - yml_or_file = "in the description file" - description_path = ( - f"{os.path.splitext(self.file_path)[0]}_description.md" - ) - - if not Path(description_path).exists(): - error_message, error_code = Errors.no_description_file_warning() - self.handle_error( - error_message, - error_code, - file_path=self.file_path, - warning=True, - ) - return True - - # running on a description file so the file path is the description path - else: - description_path = self.file_path - integration_path = self.file_path.replace("_description.md", ".yml") - yml_or_file = "in the description file" - - if description_path: - with open(description_path) as f: - description_content = f.read() - - invalid_lines = [] - for line_num, line in enumerate(description_content.split("\n")): - if "demisto " in line.lower() or " demisto" in line.lower(): - invalid_lines.append(line_num + yml_line_num + 1) - - if invalid_lines: - error_message, error_code = Errors.description_contains_demisto_word( - invalid_lines, yml_or_file - ) - - if self.handle_error( - error_message, - error_code, - file_path=integration_path, - ): - self._is_valid = False - return False - - return True - def has_markdown_lint_errors(self, file_content: str): if mdx_server_is_up(): markdown_response = run_markdownlint(file_content) diff --git a/demisto_sdk/commands/common/hook_validations/readme.py b/demisto_sdk/commands/common/hook_validations/readme.py index af0d7d52550..09adcf7f2a9 100644 --- a/demisto_sdk/commands/common/hook_validations/readme.py +++ b/demisto_sdk/commands/common/hook_validations/readme.py @@ -196,7 +196,6 @@ def is_valid_file(self) -> bool: self.verify_no_default_sections_left(), self.verify_readme_is_not_too_short(), self.is_context_different_in_yml(), - self.verify_demisto_in_readme_content(), self.verify_template_not_in_readme(), self.verify_copyright_section_in_readme_content(), # self.has_no_markdown_lint_errors(), @@ -641,33 +640,6 @@ def check_readme_content_contain_text( return invalid_lines - @error_codes("RM106") - def verify_demisto_in_readme_content(self): - """ - Checks if there are the word 'Demisto' in the README content. - - Return: - True if 'Demisto' does not exist in the README content, and False if it does. - """ - - # Checks if the Readme.md is in the main repo. - if str(self.file_path.parent) == self.content_path: - return True - - is_valid = True - invalid_lines = self.check_readme_content_contain_text( - text_list=["demisto ", " demisto"], is_lower=True - ) - - if invalid_lines: - error_message, error_code = Errors.readme_contains_demisto_word( - invalid_lines - ) - if self.handle_error(error_message, error_code, file_path=self.file_path): - is_valid = False - - return is_valid - @error_codes("RM115") def has_no_markdown_lint_errors(self): """ diff --git a/demisto_sdk/commands/common/tests/description_test.py b/demisto_sdk/commands/common/tests/description_test.py index dde38c70d8b..1b994db7a82 100644 --- a/demisto_sdk/commands/common/tests/description_test.py +++ b/demisto_sdk/commands/common/tests/description_test.py @@ -166,61 +166,3 @@ def test_is_invalid_description_integration_name(repo): description_validator = DescriptionValidator(new_name) assert not description_validator.is_valid_description_name() - - -def test_demisto_in_description(repo): - """ - Given - - An integration description with the word 'Demisto'. - - When - - Running verify_demisto_in_description_content. - - Then - - Ensure that the validation fails. - """ - - pack = repo.create_pack("PackName") - integration = pack.create_integration("IntName") - integration.create_default_integration() - integration.description.write( - "This checks if we have the word Demisto in the description." - ) - - with ChangeCWD(repo.path): - description_validator = DescriptionValidator(integration.yml.path) - - assert not description_validator.verify_demisto_in_description_content() - - description_validator = DescriptionValidator(integration.description.path) - - assert not description_validator.verify_demisto_in_description_content() - - -def test_demisto_not_in_description(repo): - """ - Given - - An integration description without the word 'Demisto'. - - When - - Running verify_demisto_in_description_content. - - Then - - Ensure that the validation passes. - """ - - pack = repo.create_pack("PackName") - integration = pack.create_integration("IntName") - integration.create_default_integration() - integration.description.write( - "This checks if we have the word XSOAR in the description." - ) - - with ChangeCWD(repo.path): - description_validator = DescriptionValidator(integration.yml.path) - - assert description_validator.verify_demisto_in_description_content() - - description_validator = DescriptionValidator(integration.description.path) - - assert description_validator.verify_demisto_in_description_content() diff --git a/demisto_sdk/commands/common/tests/readme_test.py b/demisto_sdk/commands/common/tests/readme_test.py index 5e898788c47..c4cea76b176 100644 --- a/demisto_sdk/commands/common/tests/readme_test.py +++ b/demisto_sdk/commands/common/tests/readme_test.py @@ -510,92 +510,12 @@ def test_invalid_short_file(mocker, caplog): assert short_readme_error in caplog.text -def test_demisto_in_integration_readme(repo): - """ - Given - - An integration README contains the word 'Demisto'. - - When - - Running verify_demisto_in_readme_content. - - Then - - Ensure that the validation fails. - """ - - pack = repo.create_pack("PackName") - integration = pack.create_integration("IntName") - - readme_path = glob.glob( - os.path.join(os.path.dirname(integration.yml.path), "*README.md") - )[0] - - with open(readme_path, "w") as f: - f.write("This checks if we have the word Demisto in the README.") - - with ChangeCWD(repo.path): - readme_validator = ReadMeValidator(integration.readme.path) - - assert not readme_validator.verify_demisto_in_readme_content() - - def init_readmeValidator(readme_validator, repo, readme_path): readme_validator.content_path = str(repo.path) readme_validator.file_path = readme_path readme_validator.specific_validations = None -def test_demisto_in_repo_readme(mocker, repo): - """ - Given - - A repo README contains the word 'Demisto'. - - When - - Running verify_demisto_in_readme_content. - - Then - - Ensure that the validation not fails. - """ - from pathlib import Path - - readme_path = Path(repo.path) / "README.md" - mocker.patch.object(ReadMeValidator, "__init__", return_value=None) - - with open(readme_path, "w") as f: - f.write("This checks if we have the word Demisto in the README.") - - with ChangeCWD(repo.path): - readme_validator = ReadMeValidator() - init_readmeValidator(readme_validator, repo, readme_path) - assert readme_validator.verify_demisto_in_readme_content() - - -def test_demisto_not_in_readme(repo): - """ - Given - - An integration README without the word 'Demisto'. - - When - - Running verify_demisto_in_readme_content. - - Then - - Ensure that the validation passes. - """ - - pack = repo.create_pack("PackName") - integration = pack.create_integration("IntName") - - readme_path = glob.glob( - os.path.join(os.path.dirname(integration.yml.path), "*README.md") - )[0] - - with open(readme_path, "w") as f: - f.write("This checks if we have the word XSOAR in the README.") - - readme_validator = ReadMeValidator(integration.readme.path) - - assert readme_validator.verify_demisto_in_readme_content() - - def test_verify_template_not_in_readme(repo): """ Given diff --git a/demisto_sdk/commands/validate/sdk_validation_config.toml b/demisto_sdk/commands/validate/sdk_validation_config.toml index 83e1e90b2d9..0eda35e9e2f 100644 --- a/demisto_sdk/commands/validate/sdk_validation_config.toml +++ b/demisto_sdk/commands/validate/sdk_validation_config.toml @@ -13,7 +13,6 @@ ignorable_errors = [ "BA125", "BA127", "GF102", - "DS107", "DS108", "IF100", "IF106", @@ -80,7 +79,8 @@ ignorable_errors = [ "LO107", "DB100", "GR103", - "GR107" + "GR107", + "RM117" ] [Custom_Categories] @@ -420,7 +420,6 @@ select = [ "DS104", "DS105", "DS106", - "DS107", "DS108", "SC100", "SC105", @@ -439,6 +438,7 @@ select = [ "RM114", "RM115", "RM116", + "RM117", "CL100", "PR101", "CR102", diff --git a/demisto_sdk/commands/validate/tests/DS_validators_test.py b/demisto_sdk/commands/validate/tests/DS_validators_test.py index e89819e75a0..07d82ebf8c0 100644 --- a/demisto_sdk/commands/validate/tests/DS_validators_test.py +++ b/demisto_sdk/commands/validate/tests/DS_validators_test.py @@ -75,58 +75,6 @@ def test_DescriptionMissingInBetaIntegrationValidator_obtain_invalid_content_ite assert result_len == len(invalid_content_items) -def test_IsDescriptionContainsDemistoWordValidator_obtain_invalid_content_items(): - """ - Given - - Integration with a valid description. - When - - Calling the IsContainDemistoWordValidator obtain_invalid_content_items function. - Then - - Should pass. - - """ - from demisto_sdk.commands.validate.validators.DS_validators.DS107_is_description_contains_demisto_word import ( - IsDescriptionContainsDemistoWordValidator, - ) - - integration = create_integration_object() - integration.description_file.file_content_str = "valid description\n" - invalid_content_items = ( - IsDescriptionContainsDemistoWordValidator().obtain_invalid_content_items( - [integration] - ) - ) - assert len(invalid_content_items) == 0 - - -def test_IsDescriptionContainsDemistoWordValidator_is_invalid(): - """ - Given - - Integration with invalid description that contains the word 'demisto'. - When - - Calling the IsContainDemistoWordValidator obtain_invalid_content_items function. - Then - - Make that the right error message is returned. - """ - from demisto_sdk.commands.validate.validators.DS_validators.DS107_is_description_contains_demisto_word import ( - IsDescriptionContainsDemistoWordValidator, - ) - - integration = create_integration_object() - integration.description_file.file_content_str = ( - " demisto.\n demisto \n valid description\ndemisto" - ) - invalid_content_items = ( - IsDescriptionContainsDemistoWordValidator().obtain_invalid_content_items( - [integration] - ) - ) - assert ( - invalid_content_items[0].message - == "Invalid keyword 'demisto' was found in lines: 1, 2, 4. For more information about the description file See: https://xsoar.pan.dev/docs/documentation/integration-description." - ) - - @pytest.mark.parametrize( "is_beta_integration, description_file_content, result_len", [ diff --git a/demisto_sdk/commands/validate/tests/RM_validators_test.py b/demisto_sdk/commands/validate/tests/RM_validators_test.py index e5e7a8a3d0e..2736b877a48 100644 --- a/demisto_sdk/commands/validate/tests/RM_validators_test.py +++ b/demisto_sdk/commands/validate/tests/RM_validators_test.py @@ -28,9 +28,6 @@ from demisto_sdk.commands.validate.validators.RM_validators.RM105_is_pack_readme_not_equal_pack_description import ( IsPackReadmeNotEqualPackDescriptionValidator, ) -from demisto_sdk.commands.validate.validators.RM_validators.RM106_is_contain_demisto_word import ( - IsContainDemistoWordValidator, -) from demisto_sdk.commands.validate.validators.RM_validators.RM107_is_template_sentence_in_readme import ( IsTemplateInReadmeValidator, ) @@ -58,7 +55,7 @@ from demisto_sdk.commands.validate.validators.RM_validators.RM116_missing_playbook_image import ( MissingPlaybookImageValidator, ) -from demisto_sdk.commands.validate.validators.RM_validators.RM116_readme_not_to_short import ( +from demisto_sdk.commands.validate.validators.RM_validators.RM117_readme_not_to_short import ( NotToShortReadmeValidator, ) from TestSuite.repo import ChangeCWD @@ -448,58 +445,6 @@ def test_IsReadmeExistsValidator_obtain_invalid_content_items( ) -def test_IsContainDemistoWordValidator_obtain_invalid_content_items(): - """ - Given - content_items. - - Two valid pack_metadatas: - - 1 pack with valid readme text. - - 1 pack with an empty readme. When - - Calling the IsContainDemistoWordValidator obtain_invalid_content_items function. - Then - - Make sure that the pack isn't failing. - - Should pass all. - """ - content_items = [ - create_pack_object(readme_text="This is a valid readme."), - create_pack_object(readme_text=""), - ] - results = IsContainDemistoWordValidator().obtain_invalid_content_items( - content_items - ) - expected_msg = [] - assert len(results) == 0 - assert all( - [ - result.message == expected_msg - for result, expected_msg in zip(results, expected_msg) - ] - ) - - -def test_IsContainDemistoWordValidator_is_invalid(): - """ - Given - content_items. - - One invalid pack_metadata with a readme that contains the word 'demisto'. - When - - Calling the IsContainDemistoWordValidator obtain_invalid_content_items function. - Then - - Make sure the right amount of pack failed, and that the right error message is returned. - """ - content_items = [ - create_pack_object( - readme_text="Invalid readme contains the word demistomock\ndemisto \ndemisto \ndemisto.\n mockdemisto." - ) - ] - expected_msg = "Invalid keyword 'demisto' was found in lines: 1, 2, 3, 4, 5 of the README file. For more information about the README See https://xsoar.pan.dev/docs/documentation/readme_file." - results = IsContainDemistoWordValidator().obtain_invalid_content_items( - content_items - ) - assert len(results) == 1 - assert results[0].message == expected_msg - - def test_ImagePathIntegrationValidator_obtain_invalid_content_items_valid_case(): """ Given diff --git a/demisto_sdk/commands/validate/tests/old_validators_test.py b/demisto_sdk/commands/validate/tests/old_validators_test.py index 23483e410a4..9732378c405 100644 --- a/demisto_sdk/commands/validate/tests/old_validators_test.py +++ b/demisto_sdk/commands/validate/tests/old_validators_test.py @@ -3206,22 +3206,15 @@ def test_validate_no_disallowed_terms_in_customer_facing_docs_end_to_end(repo, c [ ( {"Packs/test/.pack-ignore"}, - "[file:test.yml]\nignore=BA108,BA109\n", - "[file:test.yml]\nignore=BA108,BA109,DS107\n", - "", - {"Packs/test/Integrations/test/test.yml"}, - ), - ( - {"Packs/test/.pack-ignore"}, - "[file:test.yml]\nignore=BA108,BA109,DS107\n", - "[file:test.yml]\nignore=BA108,BA109,DS107\n", + "[file:test.yml]\nignore=BA108,BA109,\n", + "[file:test.yml]\nignore=BA108,BA109,\n", "", set(), ), ( {"Packs/test1/.pack-ignore"}, - "[file:test.yml]\nignore=BA108,BA109,DS107\n", - "[file:test2.yml]\nignore=BA108,BA109,DS107\n", + "[file:test.yml]\nignore=BA108,BA109,\n", + "[file:test2.yml]\nignore=BA108,BA109,\n", "", { "Packs/test1/Integrations/test/test.yml", @@ -3239,9 +3232,9 @@ def test_validate_no_disallowed_terms_in_customer_facing_docs_end_to_end(repo, c ), ( {"Packs/test1/.pack-ignore"}, - "[file:test.yml]\nignore=BA108,BA109,DS107\n[file:test2.yml]\nignore=BA108,BA109,DS107\n", + "[file:test.yml]\nignore=BA108,BA109,\n[file:test2.yml]\nignore=BA108,BA109,\n", {}, - "[file:test.yml]\nignore=BA108,BA109,DS107\n", + "[file:test.yml]\nignore=BA108,BA109,\n", {"Packs/test1/Integrations/test2/test2.yml"}, ), ( @@ -3374,7 +3367,7 @@ def test_get_all_files_edited_in_pack_ignore_with_git_error(mocker, caplog): validate_manager = OldValidateManager() config = ConfigParser(allow_no_value=True) - config.read_string("[file:test.yml]\nignore=BA108,BA109,DS107") + config.read_string("[file:test.yml]\nignore=BA108,BA109") mocker.patch( "demisto_sdk.commands.validate.old_validate_manager.get_pack_ignore_content", diff --git a/demisto_sdk/commands/validate/validators/DS_validators/DS107_is_description_contains_demisto_word.py b/demisto_sdk/commands/validate/validators/DS_validators/DS107_is_description_contains_demisto_word.py deleted file mode 100644 index 6c842d0e292..00000000000 --- a/demisto_sdk/commands/validate/validators/DS_validators/DS107_is_description_contains_demisto_word.py +++ /dev/null @@ -1,52 +0,0 @@ -from __future__ import annotations - -from typing import Iterable, List - -from demisto_sdk.commands.common.constants import GitStatuses -from demisto_sdk.commands.common.tools import search_substrings_by_line -from demisto_sdk.commands.content_graph.objects.integration import Integration -from demisto_sdk.commands.content_graph.parsers.related_files import RelatedFileType -from demisto_sdk.commands.validate.validators.base_validator import ( - BaseValidator, - ValidationResult, -) - -ContentTypes = Integration - - -class IsDescriptionContainsDemistoWordValidator(BaseValidator[ContentTypes]): - error_code = "DS107" - description = ( - "Validate that none of the description lines contains the the word 'demisto'." - ) - rationale = ( - "Ensure that the current name of the product is used rather than the old one." - ) - error_message = "Invalid keyword 'demisto' was found in lines: {0}. For more information about the description file See: https://xsoar.pan.dev/docs/documentation/integration-description." - related_field = "description" - is_auto_fixable = False - expected_git_statuses = [GitStatuses.ADDED, GitStatuses.MODIFIED] - related_file_type = [RelatedFileType.DESCRIPTION_File] - - def obtain_invalid_content_items( - self, content_items: Iterable[ContentTypes] - ) -> List[ValidationResult]: - return [ - ValidationResult( - validator=self, - message=self.error_message.format(", ".join(lines_contain_demsito)), - content_object=content_item, - ) - for content_item in content_items - if ( - lines_contain_demsito := search_substrings_by_line( - phrases_to_search=["demisto"], - ignore_case=True, - text=content_item.description_file.file_content, - exceptionally_allowed_substrings=[ - "/demisto/", # in URL - "Demisto Bot", # expected pair. - ], - ) - ) - ] diff --git a/demisto_sdk/commands/validate/validators/RM_validators/RM106_is_contain_demisto_word.py b/demisto_sdk/commands/validate/validators/RM_validators/RM106_is_contain_demisto_word.py deleted file mode 100644 index 0e08a9e33a3..00000000000 --- a/demisto_sdk/commands/validate/validators/RM_validators/RM106_is_contain_demisto_word.py +++ /dev/null @@ -1,58 +0,0 @@ -from __future__ import annotations - -from typing import Iterable, List, Union - -from demisto_sdk.commands.common.constants import GitStatuses -from demisto_sdk.commands.common.tools import search_substrings_by_line -from demisto_sdk.commands.content_graph.objects.integration import Integration -from demisto_sdk.commands.content_graph.objects.pack import Pack -from demisto_sdk.commands.content_graph.objects.playbook import Playbook -from demisto_sdk.commands.content_graph.objects.script import Script -from demisto_sdk.commands.content_graph.parsers.related_files import RelatedFileType -from demisto_sdk.commands.validate.validators.base_validator import ( - BaseValidator, - ValidationResult, -) - -ContentTypes = Union[Pack, Integration, Script, Playbook] - - -class IsContainDemistoWordValidator(BaseValidator[ContentTypes]): - error_code = "RM106" - description = ( - "Validate that none of the readme lines contains the the word 'demisto'." - ) - rationale = ( - "Ensure that the current name of the product is used rather than the old one." - ) - error_message = "Invalid keyword 'demisto' was found in lines: {0} of the README file. For more information about the README See https://xsoar.pan.dev/docs/documentation/readme_file." - related_field = "readme" - is_auto_fixable = False - related_file_type = [RelatedFileType.README] - expected_git_statuses = [GitStatuses.ADDED, GitStatuses.MODIFIED] - - def obtain_invalid_content_items( - self, content_items: Iterable[ContentTypes] - ) -> List[ValidationResult]: - return [ - ValidationResult( - validator=self, - message=self.error_message.format(", ".join(lines_contain_demsito)), - content_object=content_item, - ) - for content_item in content_items - if ( - lines_contain_demsito := search_substrings_by_line( - phrases_to_search=["demisto"], - ignore_case=True, - text=content_item.readme.file_content, - exceptionally_allowed_substrings=[ - "/demisto/", - "devdemisto", - "demistodev", - "@demisto", - "-demisto", - ], - ) - ) - ] diff --git a/demisto_sdk/commands/validate/validators/RM_validators/RM116_readme_not_to_short.py b/demisto_sdk/commands/validate/validators/RM_validators/RM117_readme_not_to_short.py similarity index 98% rename from demisto_sdk/commands/validate/validators/RM_validators/RM116_readme_not_to_short.py rename to demisto_sdk/commands/validate/validators/RM_validators/RM117_readme_not_to_short.py index 8c501687fed..35e8395d400 100644 --- a/demisto_sdk/commands/validate/validators/RM_validators/RM116_readme_not_to_short.py +++ b/demisto_sdk/commands/validate/validators/RM_validators/RM117_readme_not_to_short.py @@ -15,8 +15,8 @@ class NotToShortReadmeValidator(BaseValidator[ContentTypes]): - error_code = "RM116" - description = "Validate that the readme file is not to short" + error_code = "RM117" + description = "Validate that the readme file is not to short." error_message = """Your Pack README is too short ({0} chars). Please move its content to the pack description or add more useful information to the Pack README. Pack README files are expected to include a few sentences about the pack and/or images.""" related_field = "readme" rationale = "Ensure better documentation."