Uh oh!
There was an error while loading. Please reload this page.
Restore context on listen in UVStreamServer. Fix #305 - #306
Conversation
fantix
left a comment
There was a problem hiding this comment.
Other than the unstable test issue, I'm okay with this PR. Thanks!
| # Let all transports shutdown. | ||
| await asyncio.sleep(0.1) |
There was a problem hiding this comment.
Using sleep is generally not recommended for new tests in uvloop - this test is actually unstable, I could get a false OK if the srv.close() got called before the connection is fully established.
A proper fix is to use a Future, set in factory() and awaited in test() - we could even pass over the assertion error in this manner. With this fix, the ResourceWarning is also gone.
fantix
left a comment
There was a problem hiding this comment.
Please see suggested changes below - could you please also rebase your commits to latest master so that the test suite may pass? Thanks!
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
1st1
commented
Mar 31, 2020
This particular fix is OK, but we need to fix this for all other "native" callbacks in uvloop in a more systematic way. |
fantix
commented
Feb 5, 2021
Merged in #348. Thanks for the PR! |
No description provided.