{"record":{"id":"2ac4e9257a4d6ba4","repo":"invoke-ai/InvokeAI","slug":"call-saved-workflow-batch-child-workflow-node-no-2ac4e9","errorCode":null,"errorMessage":"call_saved_workflow batch child workflow node '{node_id}' is not connected to any invocation input","messagePattern":"call_saved_workflow batch child workflow node '(.+?)' is not connected to any invocation input","errorType":"validation","errorClass":"UnsupportedWorkflowNodeError","httpStatus":null,"severity":"error","filePath":"invokeai/app/services/session_processor/workflow_call_batch.py","lineNumber":611,"sourceCode":"                _resolve_generator_items(generator_node, services, user_id, maximum_children)\n                if resolve_generator_items\n                else _get_generator_placeholder_items(generator_node)\n            )\n            used_generator_node_ids.add(generator_source_id)\n            if not batch_items:\n                raise UnsupportedWorkflowNodeError(\n                    f\"call_saved_workflow generator-backed batch child workflow node '{generator_source_id}' produced no batch items\"\n                )\n        else:\n            batch_items = _get_batch_items(node_data, field_name)\n            if not batch_items:\n                raise UnsupportedWorkflowNodeError(\n                    f\"call_saved_workflow batch child workflow node '{node_id}' must provide at least one batch item\"\n                )\n        batch_group_id = _get_batch_group_id(node_data)\n        destinations = _resolve_batch_destinations(node_id, field_name, workflow_nodes, workflow_edges)\n        if not destinations:\n            raise UnsupportedWorkflowNodeError(\n                f\"call_saved_workflow batch child workflow node '{node_id}' is not connected to any invocation input\"\n            )\n        group_batch_data = batch_data_by_group.setdefault(batch_group_id, [])\n        for destination_node_id, destination_field in destinations:\n            group_batch_data.append(\n                BatchDatum(\n                    node_path=destination_node_id,\n                    field_name=destination_field,\n                    items=_normalize_batch_item_for_destination(destination_field, batch_items),\n                )\n            )\n\n    if not batch_data_by_group:\n        raise UnsupportedWorkflowNodeError(\"call_saved_workflow batch child workflow contains no supported batch nodes\")\n\n    _reject_unrelated_generator_nodes(mutable_workflow, used_generator_node_ids)\n    sanitized_workflow = _build_child_graph_workflow(mutable_workflow, used_generator_node_ids)\n    child_graph = build_graph_from_workflow(sanitized_workflow)","sourceCodeStart":593,"sourceCodeEnd":629,"githubUrl":"https://github.com/invoke-ai/InvokeAI/blob/0b6a024f2ff6a86bfb953dcdb9cc504ef7397a06/invokeai/app/services/session_processor/workflow_call_batch.py#L593-L629","documentation":"A batch node in the called saved workflow has valid items but its output is not connected to any invocation input field. InvokeAI requires each batch datum to have a concrete destination node/field, otherwise it could not inject per-child field values, so it raises UnsupportedWorkflowNodeError.","triggerScenarios":"build_batch_child_workflow_session_results calls _resolve_batch_destinations for a supported batch node and no default edges lead from the batch output into any other node's input in the workflow graph.","commonSituations":"Deleting the edge out of a batch/iterate node while restructuring a workflow; a saved workflow where the batch output is connected only to a note/output node rather than an invocation; partial workflow imports missing edges.","solutions":["Open the saved workflow and connect the batch node's output to at least one invocation node's input field.","Check for edges of non-default type (e.g. collapsed/hidden edges) — only 'default' edges count as destinations; re-add as a normal edge.","Remove the batch node if it is unused, so the workflow contains only supported, connected batch nodes.","Programmatically validate: for each supported batch node, assert _resolve_batch_destinations-like edge scan finds >=1 target before calling."],"exampleFix":"// before (no outgoing edge)\n{\"nodes\":[batch1, denoise], \"edges\":[]}\n// after\n{\"edges\":[{\"source\":\"batch1\",\"target\":\"denoise\",\"type\":\"default\"}]}","handlingStrategy":"validation","validationCode":"def batch_nodes_connected(workflow, batch_ids):\n    targets = {e.get(\"source\") for e in workflow.get(\"edges\", []) if e.get(\"type\") == \"default\"}\n    return all(bid in targets for bid in batch_ids)","typeGuard":"def has_outgoing_default_edge(node_id, edges) -> bool:\n    return any(e.get(\"source\") == node_id and e.get(\"type\") == \"default\" for e in edges)","tryCatchPattern":"try:\n    results = build_batch_child_workflow_session_results(...)\nexcept UnsupportedWorkflowNodeError as e:\n    if \"not connected to any invocation input\" in str(e):\n        raise WorkflowConfigError(\"connect batch output to an invocation input\") from e","preventionTips":["Check edge integrity after editing or importing workflows","Connect batch outputs before saving; delete unused batch nodes","Run graph validation (edges non-empty for batch nodes) in CI for saved workflows","Avoid connecting batch outputs only to non-invocation nodes"],"tags":["invokeai","batch","workflow-call","graph-connectivity"],"backgroundTag":"batch-node-unconnected","analyzedSha":"0b6a024f2ff6a86bfb953dcdb9cc504ef7397a06","analyzedAt":"2026-08-29T04:46:49.967Z","schemaVersion":2},"datasetVersion":"2026-08-29T07:17:48.351Z"}