-
-
Notifications
You must be signed in to change notification settings - Fork 30.1k
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
investigate task/future cancellation in asynciomodule.c #79053
Comments
Vladimir Matveev has discovered that C and Python implementation of asyncio.Task diverge:
In tasks.py we call "fut_obj.cancel()", so either "Task.cancel()" or "Future.cancel()" can be called depending on what "fut_obj" is. In asynciomodule.c we essentially always call "Future.cancel(fut_obj)". This probably leads to unexpected behaviour if "fut_obj" is either a Task or a Task subclass with an overloaded "cancel()" method. We need to first write a set of tests to understand the scope of this; then we'll need to patch asynciomodule.c and backport this to 3.7 & 3.6. |
Elvis, please take a look at this. |
Ned, will we have 3.7.1rc2? If so, would it be possible to include the fix for this one? |
Ned, elevating this to "release blocker", see https://bugs.python.org/msg326928 Feel free to close this issue. |
Prior to this, there were no plans to have a 3.7.1rc2. We have three options:
What's your assessment of the risk of option 2? |
Let's not rush it in without testing, for sure. Having 3.7.1rc2 would be great, but really up to you. |
Seems this change introduced a compiler warning. /home/serhiy/py/cpython3.7/Modules/_asynciomodule.c: In function ‘task_step_impl’: |
Is there any reason this issue needs to remain open? Or can we at least remove the "release blocker" priority? |
Closing it now, Ned, thanks! I assume it will make it into 3.7.1rc2, right? |
Both 3.7.1rc2 and 3.6.7rc2 |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: