-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Modify _drain_helper() to handle parallel calls without race-condition #6028
Conversation
…out race-condition.
Codecov Report
@@ Coverage Diff @@
## master #6028 +/- ##
==========================================
+ Coverage 93.32% 96.72% +3.39%
==========================================
Files 102 44 -58
Lines 30140 9857 -20283
Branches 2696 1593 -1103
==========================================
- Hits 28129 9534 -18595
+ Misses 1837 183 -1654
+ Partials 174 140 -34
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
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.
OK, got your idea.
Smart.
Thank you.
Backport to 3.8: 💚 backport PR created✅ Backport PR branch: Backported as #6146 🤖 @patchback |
#6028) * Modify _drain_helper() to handle parallel calls of _send_frame() without race-condition. * Update CHANGES/2934.bugfix * Update 2934.bugfix Co-authored-by: Andrew Svetlov <[email protected]> (cherry picked from commit 3eea7b8)
#6028) * Modify _drain_helper() to handle parallel calls of _send_frame() without race-condition. * Update CHANGES/2934.bugfix * Update 2934.bugfix Co-authored-by: Andrew Svetlov <[email protected]>
💚 Backport successfulThe PR was backported to the following branches:
|
#6028) (#6147) * Modify _drain_helper() to handle parallel calls of _send_frame() without race-condition. * Update CHANGES/2934.bugfix * Update 2934.bugfix Co-authored-by: Andrew Svetlov <[email protected]> Co-authored-by: Nándor Mátravölgyi <[email protected]> Co-authored-by: Andrew Svetlov <[email protected]>
#6028) (#6146) * Modify _drain_helper() to handle parallel calls of _send_frame() without race-condition. * Update CHANGES/2934.bugfix * Update 2934.bugfix Co-authored-by: Andrew Svetlov <[email protected]> (cherry picked from commit 3eea7b8) Co-authored-by: Nándor Mátravölgyi <[email protected]>
What do these changes do?
These changes fix a bug/race-condition on the BaseProtocol's drain-waiter.
Are there changes in behavior for the user?
There are no API or behavioral changes. This should exclusively handle the case of the race-condition when multiple coroutines produce messages to a websocket for example.
Related issue number
This fix is aimed at the #2934 issue directly.
Checklist
CONTRIBUTORS.txt
CHANGES
folder<issue_id>.<type>
for example (588.bugfix)issue_id
change it to the pr id after creating the pr.feature
: Signifying a new feature..bugfix
: Signifying a bug fix..doc
: Signifying a documentation improvement..removal
: Signifying a deprecation or removal of public API..misc
: A ticket has been closed, but it is not of interest to users.