Skip to content

Commit 84d9f8b

Browse files
committed
fix(shallow): encode blob bytes in shallow implementations
- Add _encode_blob() in ShallowRedisSaver.put_writes() - Add _encode_blob() in AsyncShallowRedisSaver.aput_writes() - Completes blob encoding fix across ALL implementations (regular and shallow)
1 parent e317d60 commit 84d9f8b

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

langgraph/checkpoint/redis/ashallow.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -534,7 +534,7 @@ async def aput_writes(
534534
"idx": WRITES_IDX_MAP.get(channel, idx),
535535
"channel": channel,
536536
"type": type_,
537-
"blob": blob,
537+
"blob": self._encode_blob(blob), # Encode bytes to base64 string for Redis
538538
}
539539
writes_objects.append(write_obj)
540540

langgraph/checkpoint/redis/shallow.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -529,7 +529,7 @@ def put_writes(
529529
"idx": WRITES_IDX_MAP.get(channel, idx),
530530
"channel": channel,
531531
"type": type_,
532-
"blob": blob,
532+
"blob": self._encode_blob(blob), # Encode bytes to base64 string for Redis
533533
}
534534
writes_objects.append(write_obj)
535535

0 commit comments

Comments
 (0)