-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
PEP 795: Deep Immutability in Python #4468
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
All commit authors signed the Contributor License Agreement.
b2bf4aa to
7cedb55
Compare
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 there a programmatic/text source that this file was created from? If so, it would be useful to include that, and also consider using an SVG file rather than a PNG.
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.
Hmm. We followed PEP12 which says:
Lines 604 to 605 in b5ae2b1
Maybe this is outdated instructions?
Currently the file was extracted from Keynote which is macOS-only. We could redraw this in a more accessible format perhaps.
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.
Yes, we can now support & prefer SVG files. If Keynote will export an SVG, that should be fine? I had wondered if you'd used e.g. TikZ or graphviz to make the image.
7cedb55 to
a0e0432
Compare
a0e0432 to
36b46c8
Compare
AA-Turner
commented
Jun 19, 2025
Please avoid force pushing, we squash-merge all PRs.
For the next PEP, please wait until the initial PR is merged before opening the PEP discussion, because we want to share the official peps.python.org URL and not the PR preview that will be deleted at some point. (Pre-PEP discussions can be opened at any time.)
And especially please wait until the sponsor had confirmed sponsorship, as we the PEP number only gets officially assigned then and it can cause confusion to re-assign numbers later.
Please see PEP 1 for more details.
https://peps.python.org/pep-0001/#submitting-a-pep
Thank you!
Co-authored-by: Michael Droettboom <mdboom@gmail.com>
peps/pep-0795.rst
Outdated
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.
Isn't this for an attempt to freeze and unfreezable object? Below, it says it raises a TypeError when trying to mutate an immutable object.
See "Changes from the previous draft" for details. -- Co-authored-by: Tobias Wrigstad <tobias.wrigstad@it.uu.se> Co-authored-by: Fridtjof Stoldt <xFrednet@gmail.com> Co-authored-by: Matthew Johnson <matajoh@users.noreply.github.com>
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
This comment was marked as resolved.
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
Thanks to Cornelius Krupp for pointing these out.
As pointed out by Cornelius Krupp, types created by the namedtuple constructor are mutable.
* Added subclass info; clarified explicit objects * Bug fixes in the RST
Uh oh!
There was an error while loading. Please reload this page.
Basic requirements (all PEP Types)
pep-NNNN.rst), PR title (PEP 123: <Title of PEP>) andPEPheaderAuthororSponsor, and formally confirmed their approvalAuthor,Status(Draft),TypeandCreatedheaders filled out correctlyPEP-Delegate,Topic,RequiresandReplacesheaders completed if appropriate.github/CODEOWNERSfor the PEPStandards Track requirements
Python-Versionset to valid (pre-beta) future Python version, if relevantDiscussions-ToandPost-History📚 Documentation preview 📚: https://pep-previews--4468.org.readthedocs.build/pep-0795/