-
-
Notifications
You must be signed in to change notification settings - Fork 30.9k
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
GH-101588: Deprecate pickle/copy/deepcopy support in itertools #104965
GH-101588: Deprecate pickle/copy/deepcopy support in itertools #104965
Conversation
Lib/test/test_itertools.py
Outdated
import warnings | ||
|
||
def pickle_deprecated(testfunc): | ||
""" Run the test twice. On the first pass, verify that a |
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.
Is it worth it to run them a third time, with DeprecationWarnings promoted to errors? That usually ends up exercising paths that rarely get considered, but it'd probably be more in pickle than in itertools.
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.
Will do.
Thanks @rhettinger for the PR 🌮🎉.. I'm working now to backport this PR to: 3.12. |
…ythonGH-104965) (cherry picked from commit 402ee5a) Co-authored-by: Raymond Hettinger <rhettinger@users.noreply.github.com>
GH-104997 is a backport of this pull request to the 3.12 branch. |
Thomas, the C code deprecation and the related tests were created in a way that should be easy to review and easy to turned-off if need arises.
📚 Documentation preview 📚: https://cpython-previews--104965.org.readthedocs.build/