← 返回首页
gh-95913: Copyedit, xref and organize enum section by CAM-Gerlach · Pull Request #98295 · python/cpython · GitHub
Skip to content

Navigation Menu

Toggle navigation
Sign in
Appearance settings
Search or jump to...

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Include my email address so I can be contacted

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
Resetting focus

gh-95913: Copyedit, xref and organize enum section#98295

Merged
ezio-melotti merged 5 commits into
python:mainfrom
CAM-Gerlach:whatsnew-edit-enum-section
Oct 18, 2022
Merged

gh-95913: Copyedit, xref and organize enum section#98295
ezio-melotti merged 5 commits into
python:mainfrom
CAM-Gerlach:whatsnew-edit-enum-section

Conversation

CAM-Gerlach commented Oct 15, 2022
edited
Loading

Copy link
Copy Markdown
Member

Part of #95913 . Also intends to solve #98250 (which I hadn't seen when I first created this).

Initially, this started out as a PR adding the missing new enum APIs, but I pulled that out to a separate issue, # , and keeping this one focused on just the copyediting, cross-referencing and organization of the section, which ended up being fairly extensive.

In particular, this PR:

  • Describes the changes to __format__ and __str__ changes more clearly and comprehensively, per Enum.__str__ change could be improved in What's New #98250 (and superseding gh-98250: Improve documentation about change to Enum.__format__ #98261 )
  • Converts the code literals in the exiting enum sections to actual Sphinx cross-references to the various items discussed (a few of which didn't resolved, which highlighted that several new APIs mentioned here weren't actually documented)
  • Rewrites the section's phrasing to be consistent with the others, namely past-tense prose
  • More clearly and descriptively explains several of the new features whose items were potentially confusing or incomplete
  • Combines closely related elements which had distinct bullets, sometimes widely separated, to avoid duplication and be easier to follow
  • Applies other Sphinx syntax and semantics, and fixes other minor textual issues

Closes #98250

bedevere-bot added awaiting review docs Documentation in the Doc dir skip news labels Oct 15, 2022
CAM-Gerlach changed the title Whatsnew: Copyedit, xref and organize enum section gh-95913: Copyedit, xref and organize enum section Oct 15, 2022
CAM-Gerlach added 3.11 only security fixes needs backport to 3.11 only security fixes labels Oct 15, 2022

CAM-Gerlach commented Oct 15, 2022
edited
Loading

Copy link
Copy Markdown
Member Author

Related to, and provided the impetus for, #98298

CAM-Gerlach mentioned this pull request Oct 15, 2022
33 tasks

Copy link
Copy Markdown
Member Author

I've added some additional explanations and clarifications to further address the issue brought up in issue #98250 and incorporate the spirit of the change in PR #98261 , which I missed seeing before I submitted this PR.

mdboom left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality Hide comment

LGTM

ethanfurman left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality Hide comment

Thanks for fixing that. One change and one suggestion. :-)

Comment thread Doc/whatsnew/3.11.rst Outdated Show resolved Hide resolved
Comment thread Doc/whatsnew/3.11.rst Show resolved Hide resolved

Copy link
Copy Markdown

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 I have made the requested changes; please review again. I will then notify any core developers who have left a review that you're ready for them to take another look at this pull request.

ezio-melotti merged commit 73e5180 into python:main Oct 18, 2022

Copy link
Copy Markdown
Contributor

Thanks @CAM-Gerlach for the PR, and @ezio-melotti for merging it 🌮🎉.. I'm working now to backport this PR to: 3.11.
🐍🍒⛏🤖

Copy link
Copy Markdown

GH-98386 is a backport of this pull request to the 3.11 branch.

bedevere-bot removed the needs backport to 3.11 only security fixes label Oct 18, 2022
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Oct 18, 2022
) * Whatsnew: Convert literals in enum section to actual x-references * Whatsnew: Rewrite enum section for clear and consistant phrasing * Whatsnew: Combine directly related enum items instead of seperating them * pythongh-98250: Describe __str__/__format__ changes more clearly/accurately * Tweak enum section language per feedback from Ethan (cherry picked from commit 73e5180) Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
miss-islington added a commit that referenced this pull request Oct 18, 2022
* Whatsnew: Convert literals in enum section to actual x-references * Whatsnew: Rewrite enum section for clear and consistant phrasing * Whatsnew: Combine directly related enum items instead of seperating them * gh-98250: Describe __str__/__format__ changes more clearly/accurately * Tweak enum section language per feedback from Ethan (cherry picked from commit 73e5180) Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>

Copy link
Copy Markdown
Member Author

BTW @ethanfurman , I hate to bug you but since we're on a tight timetable for the 3.11 release, do you think you could share your thoughts on #98298 ? I can take care of adding the mentioned docs if needed (with your review), but I wanted to get your take first as the resident Enum expert and the author of most of the changes being documented. Thanks!

pablogsal pushed a commit that referenced this pull request Oct 22, 2022
* Whatsnew: Convert literals in enum section to actual x-references * Whatsnew: Rewrite enum section for clear and consistant phrasing * Whatsnew: Combine directly related enum items instead of seperating them * gh-98250: Describe __str__/__format__ changes more clearly/accurately * Tweak enum section language per feedback from Ethan (cherry picked from commit 73e5180) Co-authored-by: C.A.M. Gerlach <CAM.Gerlach@Gerlach.CAM>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3.11 only security fixes docs Documentation in the Doc dir skip news

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Enum.__str__ change could be improved in What's New

6 participants

Footer

© 2026 GitHub, Inc.