Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork34k
gh-75572: Forward-port test_xpickle from Python 2 to 3.#22452
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
Fidget-Spinner commentedSep 30, 2020
@iritkatriel , thanks for the really thorough review, I have implemented most of the suggestions |
python-cla-botbot commentedApr 18, 2025 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
serhiy-storchaka commentedJan 3, 2026
Thank you for your PR,@Fidget-Spinner. This is a great work, especially for the first contribution (you contributed after this a lot, and it was valuable contribution). Unfortunately, the PR became slightly outdated, and new conflicts were introduced. I resolved conflicts and fixed other incompatibilities:
We perhaps can make more tests supporting by moving some code to separate files, but the current version is already great. |
serhiy-storchaka commentedJan 3, 2026
By moving the testing classes to a separate module I managed to fix support for 3.5+. Only this module is shared between versions, so we have no restrictions to uise new syntax in tests. |
8735daf intopython:mainUh oh!
There was an error while loading.Please reload this page.
Thanks@Fidget-Spinner for the PR, and@serhiy-storchaka for merging it 🌮🎉.. I'm working now to backport this PR to: 3.13, 3.14. |
Sorry,@Fidget-Spinner and@serhiy-storchaka, I could not cleanly backport this to |
GH-143485 is a backport of this pull request to the3.14 branch. |
…ythonGH-22452)Move data classes used in tests to separate file test_picklecommon.py,so it can be imported in old Python versions.(cherry picked from commit8735daf)Co-authored-by: Ken Jin <kenjin@python.org>Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
…ythonGH-22452)Move data classes used in tests to separate file test_picklecommon.py,so it can be imported in old Python versions.(cherry picked from commit8735daf)(cherry picked from commitff0a8b7)Co-authored-by: Ken Jin <kenjin@python.org>Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
GH-143509 is a backport of this pull request to the3.13 branch. |
Uh oh!
There was an error while loading.Please reload this page.
https://bugs.python.org/issue31391
Apart from porting test_xpickle, a resource was also added in libregrtest's command line options (as this was originally available in Py2 but removed in Py3, and the test takes considerably long).
I have tested the code against Windows 10 and Ubuntu 20.04. It is also compatible with the py launcher in Windows (PEP 397). In total, it takes around 14 minutes to run the entire test on Ubuntu 20.04, which isn't all that surprising considering the Py2 tests took a few minutes to run, and pickletester has added many more test functions since then.
Compatible versions to bounce pickles from are Python 3.6 - 3.9. Supporting Python 3.5 wasn't feasible since the pickletester library has to be imported, and it has generous use of f-strings.
This is my first time contributing to CPython, and I'd really like feedback on how I can improve this PR, thanks!
https://bugs.python.org/issue31391