From 540c1b1c277551e161152a56d6ce7c12090b2259 Mon Sep 17 00:00:00 2001 From: "patched.codes[bot]" <298395+patched.codes[bot]@users.noreply.github.com> Date: Mon, 16 Sep 2024 02:30:52 +0000 Subject: [PATCH] Patched /tmp/tmpcbmqgz14/patchwork/steps/Combine/Combine.py --- patchwork/steps/Combine/Combine.py | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/patchwork/steps/Combine/Combine.py b/patchwork/steps/Combine/Combine.py index 2c0cc499..35d2b1d4 100644 --- a/patchwork/steps/Combine/Combine.py +++ b/patchwork/steps/Combine/Combine.py @@ -6,6 +6,27 @@ class Combine(Step): def __init__(self, inputs): + """Initialize a CombineInputs instance. + + Args: + inputs (dict): A dictionary containing the required input data. + + Returns: + None + + Raises: + """Merges two JSON objects or lists of JSON objects. + + Args: + self: The instance of the class containing base and update attributes. + + Returns: + dict or list: The merged result. If both inputs are dictionaries, returns a merged dictionary. + If both inputs are lists, returns a list of merged dictionaries. If one input is a list and + the other is a dictionary, returns a list where the dictionary is merged with each item in the list. + """ + ValueError: If any required keys are missing from the inputs dictionary. + """ super().__init__(inputs) missing_keys = CombineInputs.__required_keys__.difference(inputs.keys()) if len(missing_keys) > 0: