This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Documentation on `GenericAlias` objects and `__class_getitem__` could be improved
Type: behavior Stage: resolved
Components: Documentation Versions: Python 3.11, Python 3.10, Python 3.9
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: docs@python Nosy List: AlexWaygood, JelleZijlstra, docs@python, gvanrossum, kj, lukasz.langa, miss-islington
Priority: normal Keywords: patch

Created on 2021-10-30 20:21 by AlexWaygood, last changed 2022-04-11 14:59 by admin. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 29335 merged AlexWaygood, 2021-10-30 20:44
PR 29387 merged AlexWaygood, 2021-11-03 14:54
PR 29388 merged AlexWaygood, 2021-11-03 14:54
PR 29389 merged AlexWaygood, 2021-11-03 14:56
PR 29399 merged miss-islington, 2021-11-04 04:06
PR 29400 merged miss-islington, 2021-11-04 04:07
PR 29447 merged miss-islington, 2021-11-06 18:00
PR 29448 merged miss-islington, 2021-11-06 18:00
PR 29479 merged AlexWaygood, 2021-11-08 22:28
PR 29619 merged miss-islington, 2021-11-18 15:54
PR 29620 merged miss-islington, 2021-11-18 15:54
PR 30688 merged miss-islington, 2022-01-19 14:53
PR 30689 merged kj, 2022-01-19 15:10
PR 30690 merged kj, 2022-01-19 15:14
PR 31743 merged miss-islington, 2022-03-08 03:49
PR 31744 merged miss-islington, 2022-03-08 03:49
Messages (24)
msg405384 - (view) Author: Alex Waygood (AlexWaygood) * (Python triager) Date: 2021-10-30 20:21
The documentation on `GenericAlias` objects implies at multiple points that only container classes can implement `__class_getitem__`, and goes into very little detail about what it means for a non-container class to be parameterized.
msg405385 - (view) Author: Alex Waygood (AlexWaygood) * (Python triager) Date: 2021-10-30 20:46
This issue is related, but distinct, to previous issue https://bugs.python.org/issue42280.
msg405662 - (view) Author: Ken Jin (kj) * (Python committer) Date: 2021-11-04 04:06
New changeset e03e50377d6f8f212af60fed4ae405ebeb73237d by Alex Waygood in branch 'main':
bpo-45680: ``typing`` docs: improve links to docs on ``GenericAlias``/``__class_getitem__`` (GH-29387)
https://github.com/python/cpython/commit/e03e50377d6f8f212af60fed4ae405ebeb73237d
msg405664 - (view) Author: miss-islington (miss-islington) Date: 2021-11-04 04:27
New changeset c10896696f47a8348e6d9ea3c1d96fa6ba131a31 by Miss Islington (bot) in branch '3.10':
bpo-45680: ``typing`` docs: improve links to docs on ``GenericAlias``/``__class_getitem__`` (GH-29387)
https://github.com/python/cpython/commit/c10896696f47a8348e6d9ea3c1d96fa6ba131a31
msg405665 - (view) Author: miss-islington (miss-islington) Date: 2021-11-04 04:34
New changeset e813dd4d7bb0ecfabc7dae75e13f58164bcf8da6 by Miss Islington (bot) in branch '3.9':
bpo-45680: ``typing`` docs: improve links to docs on ``GenericAlias``/``__class_getitem__`` (GH-29387)
https://github.com/python/cpython/commit/e813dd4d7bb0ecfabc7dae75e13f58164bcf8da6
msg405871 - (view) Author: Łukasz Langa (lukasz.langa) * (Python committer) Date: 2021-11-06 18:00
New changeset 77a2c77c84d2ead2d19f96df862c119308e90071 by Alex Waygood in branch 'main':
[doc] bpo-45680: Improve glossary entry for generic types (GH-29388)
https://github.com/python/cpython/commit/77a2c77c84d2ead2d19f96df862c119308e90071
msg405876 - (view) Author: Łukasz Langa (lukasz.langa) * (Python committer) Date: 2021-11-06 18:21
New changeset 494f8da741054e5bab33f23f3961400ea5778235 by Miss Islington (bot) in branch '3.10':
[doc] bpo-45680: Improve glossary entry for generic types (GH-29388) (GH-29447)
https://github.com/python/cpython/commit/494f8da741054e5bab33f23f3961400ea5778235
msg405878 - (view) Author: Łukasz Langa (lukasz.langa) * (Python committer) Date: 2021-11-06 18:50
New changeset 643f50ca5e9e12a4d8269ddc8baf2279d8608745 by Miss Islington (bot) in branch '3.9':
[doc] bpo-45680: Improve glossary entry for generic types (GH-29388) (GH-29448)
https://github.com/python/cpython/commit/643f50ca5e9e12a4d8269ddc8baf2279d8608745
msg406542 - (view) Author: Łukasz Langa (lukasz.langa) * (Python committer) Date: 2021-11-18 15:54
New changeset 31b3a70edb1216bdc8fab3b2eafd8ddb00487f41 by Alex Waygood in branch 'main':
[doc] bpo-45680: Disambiguate ``__getitem__`` and ``__class_getitem__`` in the  data model (GH-29389)
https://github.com/python/cpython/commit/31b3a70edb1216bdc8fab3b2eafd8ddb00487f41
msg406557 - (view) Author: Łukasz Langa (lukasz.langa) * (Python committer) Date: 2021-11-18 17:34
New changeset fde9f61e70bc38850783c81bf7c80c764ba6d9fa by Miss Islington (bot) in branch '3.10':
[3.10] [doc] bpo-45680: Disambiguate ``__getitem__`` and ``__class_getitem__`` in the  data model (GH-29389) (GH-29620)
https://github.com/python/cpython/commit/fde9f61e70bc38850783c81bf7c80c764ba6d9fa
msg406558 - (view) Author: Łukasz Langa (lukasz.langa) * (Python committer) Date: 2021-11-18 17:41
New changeset 591bf416090fb00795eed51f6863e3c5d9036c89 by Miss Islington (bot) in branch '3.9':
[3.9] [doc] bpo-45680: Disambiguate ``__getitem__`` and ``__class_getitem__`` in the  data model (GH-29389) (GH-29619)
https://github.com/python/cpython/commit/591bf416090fb00795eed51f6863e3c5d9036c89
msg410954 - (view) Author: Ken Jin (kj) * (Python committer) Date: 2022-01-19 14:53
New changeset 0eae9a2a2db6cc5a72535f61bb988cc417011640 by Alex Waygood in branch 'main':
bpo-45680: Clarify documentation on ``GenericAlias`` objects (GH-29335)
https://github.com/python/cpython/commit/0eae9a2a2db6cc5a72535f61bb988cc417011640
msg410956 - (view) Author: miss-islington (miss-islington) Date: 2022-01-19 15:24
New changeset 24d0b331e81b4e4af8dd4c1b66ea7159c1fdabc5 by Miss Islington (bot) in branch '3.10':
[3.10] bpo-45680: Clarify documentation on ``GenericAlias`` objects (GH-29335) (GH-30688)
https://github.com/python/cpython/commit/24d0b331e81b4e4af8dd4c1b66ea7159c1fdabc5
msg410959 - (view) Author: Ken Jin (kj) * (Python committer) Date: 2022-01-19 15:37
New changeset 1faf7c4effbe8b66f9b0347cab570fb3b5c91fb0 by Ken Jin in branch 'main':
bpo-45680: Minor formatting fix in stdtypes.rst (GH-30690)
https://github.com/python/cpython/commit/1faf7c4effbe8b66f9b0347cab570fb3b5c91fb0
msg410966 - (view) Author: Ken Jin (kj) * (Python committer) Date: 2022-01-19 16:01
New changeset 00645166b64e68001a425a15281a1ccdcb78f818 by Ken Jin in branch '3.9':
[3.9] bpo-45680: Clarify documentation on ``GenericAlias`` objects (GH-29335) (GH-30689)
https://github.com/python/cpython/commit/00645166b64e68001a425a15281a1ccdcb78f818
msg410967 - (view) Author: Ken Jin (kj) * (Python committer) Date: 2022-01-19 16:03
Phew, we're finally done. Thanks Alex for the PRs, and Łukasz, Guido (and many others) for all the reviews!
msg410969 - (view) Author: Alex Waygood (AlexWaygood) * (Python triager) Date: 2022-01-19 16:19
Wait... there's still PR 29479 open!

But that can wait a little while -- getting PR 29335 over the line is definitely worth celebrating!!
msg411489 - (view) Author: Ken Jin (kj) * (Python committer) Date: 2022-01-24 16:22
> Wait... there's still PR 29479 open!

Sorry, I was too excited when PR 29335 merged and missed that. In the future, please re-open if you feel I closed an issue wrongly. Thanks!
msg411490 - (view) Author: Alex Waygood (AlexWaygood) * (Python triager) Date: 2022-01-24 16:28
> Sorry, I was too excited when PR 29335 merged and missed that. In the future, please re-open if you feel I closed an issue wrongly. Thanks!

No worries — will do!
msg414712 - (view) Author: Jelle Zijlstra (JelleZijlstra) * (Python committer) Date: 2022-03-08 03:50
New changeset 50731297a9b6d57eec3b3f89522785b23f7b3e71 by Alex Waygood in branch 'main':
bpo-45680: Improve docs on subscriptions w.r.t. `GenericAlias` objects (GH-29479)
https://github.com/python/cpython/commit/50731297a9b6d57eec3b3f89522785b23f7b3e71
msg414714 - (view) Author: Jelle Zijlstra (JelleZijlstra) * (Python committer) Date: 2022-03-08 03:59
And now I think we're really done! Thanks for all your work here @AlexWaygood.
msg414718 - (view) Author: miss-islington (miss-islington) Date: 2022-03-08 04:13
New changeset 06108c08ddbb4efda804eb74dd33928348102e6f by Miss Islington (bot) in branch '3.10':
bpo-45680: Improve docs on subscriptions w.r.t. `GenericAlias` objects (GH-29479)
https://github.com/python/cpython/commit/06108c08ddbb4efda804eb74dd33928348102e6f
msg414719 - (view) Author: miss-islington (miss-islington) Date: 2022-03-08 04:16
New changeset e83f084084296a9b16b83b324a715045d3614c92 by Miss Islington (bot) in branch '3.9':
bpo-45680: Improve docs on subscriptions w.r.t. `GenericAlias` objects (GH-29479)
https://github.com/python/cpython/commit/e83f084084296a9b16b83b324a715045d3614c92
msg414730 - (view) Author: Alex Waygood (AlexWaygood) * (Python triager) Date: 2022-03-08 07:55
Thanks so much to Ken, Łukasz, Jelle, Guido, and everybody else who helped review these PRs!
History
Date User Action Args
2022-04-11 14:59:51adminsetgithub: 89843
2022-03-08 07:55:01AlexWaygoodsetmessages: + msg414730
2022-03-08 04:16:00miss-islingtonsetmessages: + msg414719
2022-03-08 04:13:34miss-islingtonsetmessages: + msg414718
2022-03-08 03:59:23JelleZijlstrasetstatus: open -> closed
resolution: fixed
messages: + msg414714

stage: patch review -> resolved
2022-03-08 03:50:16JelleZijlstrasetnosy: + JelleZijlstra
messages: + msg414712
2022-03-08 03:49:59miss-islingtonsetpull_requests: + pull_request29861
2022-03-08 03:49:54miss-islingtonsetstage: resolved -> patch review
pull_requests: + pull_request29860
2022-01-24 16:28:58AlexWaygoodsetmessages: + msg411490
2022-01-24 16:22:35kjsetstatus: closed -> open
resolution: fixed -> (no value)
messages: + msg411489
2022-01-19 16:19:22AlexWaygoodsetmessages: + msg410969
2022-01-19 16:03:22kjsetstatus: open -> closed
resolution: fixed
messages: + msg410967

stage: patch review -> resolved
2022-01-19 16:01:38kjsetmessages: + msg410966
2022-01-19 15:37:16kjsetmessages: + msg410959
2022-01-19 15:24:35miss-islingtonsetmessages: + msg410956
2022-01-19 15:14:40kjsetpull_requests: + pull_request28888
2022-01-19 15:10:10kjsetpull_requests: + pull_request28887
2022-01-19 14:53:50miss-islingtonsetpull_requests: + pull_request28886
2022-01-19 14:53:50kjsetmessages: + msg410954
2021-11-18 17:41:16lukasz.langasetmessages: + msg406558
2021-11-18 17:34:18lukasz.langasetmessages: + msg406557
2021-11-18 15:54:57miss-islingtonsetpull_requests: + pull_request27855
2021-11-18 15:54:52miss-islingtonsetpull_requests: + pull_request27854
2021-11-18 15:54:38lukasz.langasetmessages: + msg406542
2021-11-08 22:28:03AlexWaygoodsetpull_requests: + pull_request27730
2021-11-06 18:50:22lukasz.langasetmessages: + msg405878
2021-11-06 18:21:43lukasz.langasetmessages: + msg405876
2021-11-06 18:00:59miss-islingtonsetpull_requests: + pull_request27702
2021-11-06 18:00:56lukasz.langasetmessages: + msg405871
2021-11-06 18:00:54miss-islingtonsetpull_requests: + pull_request27701
2021-11-04 04:34:40miss-islingtonsetmessages: + msg405665
2021-11-04 04:27:55miss-islingtonsetmessages: + msg405664
2021-11-04 04:07:14miss-islingtonsetpull_requests: + pull_request27659
2021-11-04 04:06:52miss-islingtonsetnosy: + miss-islington
pull_requests: + pull_request27658
2021-11-04 04:06:42kjsetmessages: + msg405662
2021-11-03 14:56:05AlexWaygoodsetpull_requests: + pull_request27647
2021-11-03 14:54:18AlexWaygoodsetpull_requests: + pull_request27646
2021-11-03 14:54:00AlexWaygoodsetpull_requests: + pull_request27645
2021-11-03 14:29:38AlexWaygoodsettitle: Documentation on `GenericAlias` objects could be improved -> Documentation on `GenericAlias` objects and `__class_getitem__` could be improved
2021-10-30 20:46:54AlexWaygoodsetmessages: + msg405385
2021-10-30 20:44:41AlexWaygoodsetkeywords: + patch
stage: patch review
pull_requests: + pull_request27603
2021-10-30 20:21:29AlexWaygoodcreate