{"record":{"id":"0d7648ca21259ef5","repo":"langchain-ai/langgraph","slug":"cannot-copy-checkpoint-with-multiple-updates","errorCode":null,"errorMessage":"Cannot copy checkpoint with multiple updates","messagePattern":"Cannot copy checkpoint with multiple updates","errorType":"exception","errorClass":"InvalidUpdateError","httpStatus":null,"severity":"error","filePath":"libs/langgraph/langgraph/pregel/main.py","lineNumber":1802,"sourceCode":"                    # store the writes\n                    checkpointer.put_writes(\n                        next_config,\n                        input_writes,\n                        str(uuid5(UUID(checkpoint[\"id\"]), INPUT)),\n                    )\n\n                    return patch_checkpoint_map(\n                        next_config, saved.metadata if saved else None\n                    )\n                else:\n                    raise InvalidUpdateError(\n                        f\"Received no input writes for {self.input_channels}\"\n                    )\n\n            # copy checkpoint\n            if as_node == \"__copy__\":\n                if len(updates) > 1:\n                    raise InvalidUpdateError(\n                        \"Cannot copy checkpoint with multiple updates\"\n                    )\n\n                if saved is None:\n                    raise InvalidUpdateError(\"Cannot copy a non-existent checkpoint\")\n\n                next_checkpoint = create_checkpoint(checkpoint, None, step)\n\n                # copy checkpoint\n                next_config = checkpointer.put(\n                    saved.parent_config\n                    or patch_configurable(\n                        saved.config, {CONFIG_KEY_CHECKPOINT_ID: None}\n                    ),\n                    next_checkpoint,\n                    {\n                        \"source\": \"fork\",\n                        \"step\": step + 1,","sourceCodeStart":1784,"sourceCodeEnd":1820,"githubUrl":"https://github.com/langchain-ai/langgraph/blob/38031739e551638e373fb553453256c23feeb41f/libs/langgraph/langgraph/pregel/main.py#L1784-L1820","documentation":"Raised during update_state's checkpoint-copy mode (as_node == '__copy__') when more than one update is present. Copying a checkpoint duplicates state from a single source; multiple updates are ambiguous here and rejected with InvalidUpdateError. Copy with a single update.","triggerScenarios":"Thrown at libs/langgraph/langgraph/pregel/main.py:1802 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Issue the __copy__ update alone","Split multiple updates into separate update_state calls"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"38031739e551638e373fb553453256c23feeb41f","analyzedAt":"2026-08-26T18:02:49.312Z","contentChangedAt":"2026-08-26T18:02:49.312Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}