Commit 5bdcc79
committed
fix: handle missing blob attribute in shallow checkpoint savers (#80)
Add defensive checks in AsyncShallowRedisSaver and ShallowRedisSaver
to filter out documents with None or missing blob attributes when
loading pending sends. This prevents AttributeError when querying
checkpoint writes from the TASKS channel.
Added comprehensive test for empty blob (b'') handling as suggested in PR review:
- Test empty byte string in pending sends
- Test various empty values (empty string, dict, list)
- Verify proper handling in TASKS channel writes
Fixes #801 parent 13ddc96 commit 5bdcc79
File tree
4 files changed
+468
-8
lines changed- langgraph/checkpoint/redis
- tests
4 files changed
+468
-8
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
646 | 646 | | |
647 | 647 | | |
648 | 648 | | |
| 649 | + | |
649 | 650 | | |
650 | | - | |
651 | | - | |
652 | | - | |
653 | | - | |
| 651 | + | |
654 | 652 | | |
| 653 | + | |
655 | 654 | | |
656 | 655 | | |
657 | 656 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
675 | 675 | | |
676 | 676 | | |
677 | 677 | | |
| 678 | + | |
678 | 679 | | |
679 | | - | |
680 | | - | |
681 | | - | |
682 | | - | |
| 680 | + | |
683 | 681 | | |
| 682 | + | |
684 | 683 | | |
685 | 684 | | |
686 | 685 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
248 | 248 | | |
249 | 249 | | |
250 | 250 | | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
251 | 322 | | |
252 | 323 | | |
253 | 324 | | |
| |||
0 commit comments