-
Notifications
You must be signed in to change notification settings - Fork 33
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
Fix multiple blocking binary reader issues #552
Fix multiple blocking binary reader issues #552
Conversation
- Fixes an issue where `read_from` would read fewer bytes than it was expected to. - Addded incomplete guard to an annotation consume that could cause an error when the buffer did not have enough data. - Fixed an issue where bytes read into a NBR were counted twice when determining if all data had been read. This probably wasn't an issue since `read_from` reads all of the data requested. - Implements stream completion for non-blocking binary reader. - Moves Expandable to the raw_reader module now that the binary raw reader is using it.
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #552 +/- ##
==========================================
+ Coverage 83.21% 83.25% +0.04%
==========================================
Files 86 86
Lines 16455 16537 +82
Branches 16455 16537 +82
==========================================
+ Hits 13693 13768 +75
- Misses 1562 1563 +1
- Partials 1200 1206 +6
☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The diff looks good! Could you add unit tests that cover the corner cases this addresses?
Absolutely, I'll try to push those up tomorrow. |
Pushed up some unit tests:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Glad to have this fixed, thanks!
Issue #, if available:
Description of changes:
read_from
would read fewer bytes than it was expected to.read_from
reads all of the data requested.By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.