{"record":{"id":"f410e05875d17ec8","repo":"deepset-ai/haystack","slug":"input-socket-socket-name-not-found-in-componen","errorCode":null,"errorMessage":"Input socket '{socket_name}' not found in component '{comp_name}'.\nAvailable inputs for '{comp_name}': {list(pipeline_inputs[comp_name].keys())}","messagePattern":"Input socket '(.+?)' not found in component '(.+?)'\\.\nAvailable inputs for '(.+?)': (.+?)","errorType":"exception","errorClass":"InvalidMappingValueError","httpStatus":null,"severity":"error","filePath":"haystack/core/super_component/super_component.py","lineNumber":209,"sourceCode":"            If the input mapping is of invalid type or contains invalid types.\n        :raises InvalidMappingValueError:\n            If the input mapping contains nonexistent components or sockets.\n        \"\"\"\n        if not isinstance(input_mapping, dict):\n            raise InvalidMappingTypeError(\"input_mapping must be a dictionary\")\n\n        for wrapper_input_name, pipeline_input_paths in input_mapping.items():\n            if not isinstance(pipeline_input_paths, list):\n                raise InvalidMappingTypeError(f\"Input paths for '{wrapper_input_name}' must be a list of strings.\")\n            for path in pipeline_input_paths:\n                comp_name, socket_name = self._split_component_path(path)\n                if comp_name not in pipeline_inputs:\n                    raise InvalidMappingValueError(\n                        f\"Component '{comp_name}' not found in pipeline inputs.\\n\"\n                        f\"Available components: {list(pipeline_inputs.keys())}\"\n                    )\n                if socket_name not in pipeline_inputs[comp_name]:\n                    raise InvalidMappingValueError(\n                        f\"Input socket '{socket_name}' not found in component '{comp_name}'.\\n\"\n                        f\"Available inputs for '{comp_name}': {list(pipeline_inputs[comp_name].keys())}\"\n                    )\n\n    def _resolve_input_types_from_mapping(\n        self, pipeline_inputs: dict[str, dict[str, Any]], input_mapping: dict[str, list[str]]\n    ) -> dict[str, dict[str, Any]]:\n        \"\"\"\n        Resolves and validates input types based on the provided input mapping.\n\n        This function ensures that all mapped pipeline inputs are compatible, consolidating types\n        when multiple mappings exist. It also determines whether an input is mandatory or has a default value.\n\n        :param pipeline_inputs: A dictionary containing pipeline input specifications.\n        :param input_mapping: A dictionary mapping SuperComponent inputs to pipeline socket paths.\n        :returns:\n            A dictionary specifying the resolved input types and their properties.\n        :raises InvalidMappingTypeError:","sourceCodeStart":191,"sourceCodeEnd":227,"githubUrl":"https://github.com/deepset-ai/haystack/blob/e318778c9bf60a1963e3b5f451359655dd696c30/haystack/core/super_component/super_component.py#L191-L227","documentation":"The socket part of an input_mapping path must be an input socket of the referenced component. If socket_name is not among that component's input sockets, InvalidMappingValueError is raised listing the available inputs.","triggerScenarios":"Path like ['embedder.documents'] where SentenceTransformersTextEmbedder's input is 'text'; referencing an output socket in input_mapping; typos in socket names.","commonSituations":"Confusing input and output socket names; component API changed between haystack versions (renamed sockets); using a wrong socket for components with multiple inputs.","solutions":["Use a socket that appears in pipeline.inputs()[comp_name].keys()","Check the component's run() signature for the correct input parameter name"],"exampleFix":"// before\ninput_mapping = {\"text\": [\"embedder.documents\"]}\n// after\ninput_mapping = {\"text\": [\"embedder.text\"]}","handlingStrategy":"validation","validationCode":"def check_sockets(pipe, input_mapping):\n    inputs = pipe.inputs()\n    for paths in input_mapping.values():\n        for p in paths:\n            comp, sock = p.split(\".\")\n            if sock not in inputs[comp]:\n                raise ValueError(f\"'{sock}' not an input of '{comp}': {list(inputs[comp].keys())}\")","typeGuard":"def socket_exists(pipe, path: str) -> bool:\n    comp, sock = path.split(\".\")\n    return sock in pipe.inputs().get(comp, {})","tryCatchPattern":"from haystack.core.errors import InvalidMappingValueError\ntry:\n    super_comp = SuperComponent(pipeline=pipe, input_mapping=input_mapping)\nexcept InvalidMappingValueError as e:\n    if \"Input socket\" in str(e):\n        print(\"Check component input sockets:\", e)\n    else:\n        raise","preventionTips":["Verify socket names against the component's run() signature","Consult pipeline.inputs() rather than guessing socket names","Re-check mappings after upgrading haystack (socket names can change)"],"tags":["super-component","input-mapping","unknown-socket"],"backgroundTag":"unknown-socket-reference","analyzedSha":"e318778c9bf60a1963e3b5f451359655dd696c30","analyzedAt":"2026-08-30T11:45:20.711Z","schemaVersion":2},"datasetVersion":"2026-08-30T13:17:10.514Z"}