mirror of
https://github.com/langchain-ai/langgraph.git
synced 2026-08-23 08:02:23 +02:00
The as_node INPUT, END and __copy__ paths write a checkpoint and return before create_checkpoint_plan_for_update_state_api runs, so a bulk update whose first superstep took one of them left the branch unsealed. Only INPUT actually leaked: END absorbs the base's already-run task writes, so its delta and plain channels agree. Sealing on a later superstep does not help. By then that superstep has reconstructed its value by walking through the unsealed checkpoint into the shared base, so it snapshots an already-corrupted list. The fork's first checkpoint is the one that has to carry the blob, which is what create_fork_checkpoint does. That snapshot was still being dropped by put: these paths apply writes to the input channel, not the delta channel, so nothing bumped the delta channel's version and it never entered new_versions. Pass get_next_version for the manual bump, the same reason exit mode needs it, and derive new_versions from the returned checkpoint. fork_pending tracks what is still owed, mirroring _delta_channels_awaiting_fork_snapshot in _loop.py. Caught by the Open SWE review bot on #8548.