Skip to content

[3.12] gh-50644: Forbid pickling of codecs streams (GH-109180) #109231

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

Merged
merged 1 commit into from
Oct 2, 2023

Conversation

miss-islington
Copy link
Contributor

@miss-islington miss-islington commented Sep 10, 2023

Attempts to pickle or create a shallow or deep copy of codecs streams
now raise a TypeError.

Previously, copying failed with a RecursionError, while pickling
produced wrong results that eventually caused unpickling to fail with
a RecursionError.
(cherry picked from commit d6892c2)

Co-authored-by: Serhiy Storchaka [email protected]

Attempts to pickle or create a shallow or deep copy of codecs streams
now raise a TypeError.

Previously, copying failed with a RecursionError, while pickling
produced wrong results that eventually caused unpickling to fail with
a RecursionError.
(cherry picked from commit d6892c2)

Co-authored-by: Serhiy Storchaka <[email protected]>
@Yhg1s
Copy link
Member

Yhg1s commented Sep 12, 2023

FYI, I'm delaying this until 3.12.1.

@Yhg1s Yhg1s merged commit 3e1c9e8 into python:3.12 Oct 2, 2023
@miss-islington miss-islington deleted the backport-d6892c2-3.12 branch October 2, 2023 14:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants