-
Notifications
You must be signed in to change notification settings - Fork 30
Closed
Description
Reported in the wrong repo langchain-ai/langchain-redis#94
While inspecting langgraph-checkpoint-redis 0.2.0 we noticed that the Send objects (langgraph.types.Send) are not saved correctly.
This is leading to issues with handling Interrupts - namely the user's response will not be treated as the response to the Interrupt.
This will happen inside of prepare_single_task in pregel._algo.py
if not isinstance(packet, Send):
logger.warning(
f"Ignoring invalid packet type {type(packet)} in pending sends"
)
return. <<<<< task not added
The way we overcame this is by adding a custom serializer in _default_handler:
if isinstance(obj, Send):
return {
"__send__": True,
"arg": obj.arg,
"node": obj.node,
}
and loading it back in _recursive_deserialize.
Metadata
Metadata
Assignees
Labels
No labels