[issue44174] Unclear meaning of _Private__names in enum docs.
New submission from Gregory P. Smith <greg@krypto.org>: https://docs.python.org/3/library/enum.html#private-names """ _Private__names Private names will be normal attributes in Python 3.10 instead of either an error or a member (depending on if the name ends with an underscore). Using these names in 3.9 will issue a DeprecationWarning. """ It isn't clear from this documentation what is meant by "private names". Please expand on this to be explicit about what name pattern is being described. ---------- assignee: docs@python components: Documentation messages: 393919 nosy: docs@python, gregory.p.smith priority: normal severity: normal stage: needs patch status: open title: Unclear meaning of _Private__names in enum docs. versions: Python 3.10, Python 3.11, Python 3.9 _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue44174> _______________________________________
Ken Jin <kenjin4096@gmail.com> added the comment: I think linking to this part of the docs may help https://docs.python.org/3/reference/expressions.html#atom-identifiers There's also already a label to reference to, so the sentence could start with :ref:`Private names <private-name-mangling>`. ---------- keywords: +easy, newcomer friendly nosy: +kj _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue44174> _______________________________________
Ethan Furman <ethan@stoneleaf.us> added the comment: Looks good. Patches welcome. :-) ---------- nosy: +ethan.furman _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue44174> _______________________________________
Joseph Riddle <joeriddles10@gmail.com> added the comment: _Private__names seems to no longer exist in the Python 3.11 documentation. https://docs.python.org/3.11/library/enum.html#private-names It appears to have been removed in this PR https://github.com/python/cpython/pull/23748/files Should this issue be updated to remove Python 3.11 from the Versions? ---------- nosy: +joeriddles _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue44174> _______________________________________
Ethan Furman <ethan@stoneleaf.us> added the comment: It has been moved to the tutorial (links are at the top of the Enum page). ---------- _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue44174> _______________________________________
Change by Ethan Furman <ethan@stoneleaf.us>: ---------- keywords: +patch pull_requests: +27392 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/29116 _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue44174> _______________________________________
Ethan Furman <ethan@stoneleaf.us> added the comment: New changeset 7c4d96103c4e16161e9aed9a584c9857d0674099 by Ethan Furman in branch 'main': bpo-44174: [Enum] add reference to name mangling (GH-29116) https://github.com/python/cpython/commit/7c4d96103c4e16161e9aed9a584c9857d06... ---------- _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue44174> _______________________________________
Change by Ethan Furman <ethan@stoneleaf.us>: ---------- pull_requests: +27393 pull_request: https://github.com/python/cpython/pull/29117 _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue44174> _______________________________________
Ethan Furman <ethan@stoneleaf.us> added the comment: New changeset 828722aca4ccba893f6b2e8c1d41fd74fd6e208d by Ethan Furman in branch '3.10': [3.10] bpo-44174: [Enum] add reference to name mangling (GH-29117) https://github.com/python/cpython/commit/828722aca4ccba893f6b2e8c1d41fd74fd6... ---------- _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue44174> _______________________________________
Change by Ethan Furman <ethan@stoneleaf.us>: ---------- pull_requests: +27404 pull_request: https://github.com/python/cpython/pull/29128 _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue44174> _______________________________________
Ethan Furman <ethan@stoneleaf.us> added the comment: New changeset e628700dbf2c3376502cbb5a9bff2d58d1102e16 by Ethan Furman in branch '3.9': [3.9] bpo-44174: [Enum] add name-mangling reference (GH-29128) https://github.com/python/cpython/commit/e628700dbf2c3376502cbb5a9bff2d58d11... ---------- _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue44174> _______________________________________
Change by Ethan Furman <ethan@stoneleaf.us>: ---------- resolution: -> fixed stage: patch review -> resolved status: open -> closed _______________________________________ Python tracker <report@bugs.python.org> <https://bugs.python.org/issue44174> _______________________________________
participants (4)
-
Ethan Furman
-
Gregory P. Smith
-
Joseph Riddle
-
Ken Jin