-
-
Notifications
You must be signed in to change notification settings - Fork 31.8k
bpo-36933: Remove sys.set_coroutine_wrapper (marked for removal in 3.8) #13577
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
Conversation
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.
Thanks for picking it up.
@1st1 wanted to do it but looks like he has no time now.
The PR is pretty good (but please fix my very minor note).
Python/sysmodule.c
Outdated
if (wrapper == NULL) { | ||
wrapper = Py_None; | ||
} | ||
PyObject *wrapper = Py_None; |
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.
Please use Py_RETURN_NONE
here
A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated. Once you have made the requested changes, please leave a comment on this pull request containing the phrase |
Please fix the title and commit messages of this PR. There is no such thing as "sys.set_coro_wrapper". |
I have made the requested changes; please review again I believe I've also fixed the docs building issues in CI. |
Thanks for making the requested changes! @asvetlov: please review the changes made to this pull request. |
@@ -883,6 +883,10 @@ The following features and APIs have been removed from Python 3.8: | |||
:func:`fileinput.FileInput` which was ignored and deprecated since Python 3.6 | |||
has been removed. :issue:`36952` (Contributed by Matthias Bussonnier) | |||
|
|||
* The function :func:`sys.set_coroutine_wrapper` deprecated in Python 3.7 has | |||
been removed; :func:`sys.get_coroutine_wrapper` now always return ``None``. |
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.
I don't quite get it -- what's the point of keeping sys.get_coroutine_wrapper
? Both should be removed.
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.
I don't quite get it -- what's the point of keeping sys.get_coroutine_wrapper? Both should be removed.
I remember reading to remove sys.set_coroutine_wrapper now and get_coro_wrapper later... but my memory might just be failing me. I'm happy to remove get_coro_wrapper as well.
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.
Done, and rebased (Conflict, need to regen clinic).
A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated. Once you have made the requested changes, please leave a comment on this pull request containing the phrase |
Leave get_coro_wrapper (always return None for now),
0920be7
to
409ac4a
Compare
I have made the requested changes; please review again |
Thanks! |
Sorry for that |
@Carreau would you make a PR for post-fix? |
Yes; appologies. |
See #13627 |
No problem. Thank to @1st1 for catching this. |
…8) (pythonGH-13577) It has been documented as deprecated and to be removed in 3.8; From a comment on another thread – which I can't find ; leave get_coro_wrapper() for now, but always return `None`. https://bugs.python.org/issue36933
It has been documented as deprecated and to be removed in 3.8;
From a comment on another thread – which I can't find ; leave get_coro_wrapper() for now, but always return
None
.https://bugs.python.org/issue36933