diff --git a/.changelog/4713.yml b/.changelog/4713.yml new file mode 100644 index 00000000000..493ec91bbc1 --- /dev/null +++ b/.changelog/4713.yml @@ -0,0 +1,4 @@ +changes: +- description: Fixed an issue where YmlSplitter attributes were being unintentionally updated. + type: fix +pr_number: 4713 diff --git a/demisto_sdk/commands/split/ymlsplitter.py b/demisto_sdk/commands/split/ymlsplitter.py index f33d4fe5832..977f0991867 100644 --- a/demisto_sdk/commands/split/ymlsplitter.py +++ b/demisto_sdk/commands/split/ymlsplitter.py @@ -4,6 +4,7 @@ import os import re import shutil +from copy import deepcopy from pathlib import Path from typing import Optional @@ -129,7 +130,7 @@ def extract_to_package_format( yaml_out = f"{output_path}/{base_name}.yml" logger.debug(f"Creating yml file: {yaml_out} ...") if self.yml_data: - yaml_obj = self.yml_data.copy() + yaml_obj = deepcopy(self.yml_data) else: yaml_obj = get_file(self.input, raise_on_error=True)