Skip to content

fix: handle missing blob attribute in shallow checkpoint savers (#80) #82

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 12, 2025

Conversation

bsbodden
Copy link
Contributor

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.

Fixes #80

@bsbodden bsbodden self-assigned this Aug 11, 2025
@bsbodden bsbodden requested a review from abrookins August 11, 2025 16:50
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 #80
@bsbodden bsbodden merged commit 5bdcc79 into main Aug 12, 2025
21 checks passed
@bsbodden bsbodden deleted the bsb/issue-80 branch August 12, 2025 01:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

AsyncShallowRedisSaver._aload_pending_sends fails like AsyncRedisSaver prior to 0.0.7 version
2 participants