10000 Rewrite `typing.Annotated` docs · Issue #124269 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

Rewrite typing.Annotated docs #124269

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

Closed
sobolevn opened this issue Sep 20, 2024 · 1 comment
Closed

Rewrite typing.Annotated docs #124269

sobolevn opened this issue Sep 20, 2024 · 1 comment
Labels
docs Documentation in the Doc dir topic-typing

Comments

@sobolevn
Copy link
Member
sobolevn commented Sep 20, 2024

As @JelleZijlstra said in #124125

I don't like this long bulleted list of individual issues. We should rewrite it to a more organized form.

typing.Annotated indeed has a lot bullet points in the docs: https://docs.python.org/3/library/typing.html#typing.Annotated

So, how can we be more compact about it while keeping all the details?

Linked PRs

@sobolevn sobolevn added docs Documentation in the Doc dir topic-typing labels Sep 20, 2024
@picnixz
Copy link
Member
picnixz commented Sep 20, 2024

How about grouping some features and the examples? There are some bullet points that don't have examples so they could be moved out in a paragraph directly.

Interaction with get_type_hints may be a separate paragraph as well. And limitations on duplication and metadata order could be grouped.

Finally the runtime behaviour should be a separate paragraph as well.

It doesn't reduce the length of the docs (it will be probably increased) but you won't have bullet points anymore that are indigest.

picnixz added a commit that referenced this issue Mar 14, 2025
---------

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
miss-islington pushed a commit to miss-islington/cpython that referenced this issue Mar 14, 2025
---------
(cherry picked from commit e4ac196)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
miss-islington pushed a commit to miss-islington/cpython that referenced this issue Mar 14, 2025
---------
(cherry picked from commit e4ac196)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
picnixz added a commit that referenced this issue Mar 14, 2025
gh-124269: Simplify `typing.Annotated` docs (GH-130770)

---------
(cherry picked from commit e4ac196)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
@picnixz picnixz closed this as completed Mar 14, 2025
picnixz added a commit that referenced this issue Mar 14, 2025
gh-124269: Simplify `typing.Annotated` docs (GH-130770)

---------
(cherry picked from commit e4ac196)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
mikec9 pushed a commit to mikec9/cpython that referenced this issue Mar 14, 2025
…0770) (python#131223)

pythongh-124269: Simplify `typing.Annotated` docs (pythonGH-130770)

---------
(cherry picked from commit e4ac196)

Co-authored-by: Stan Ulbrych <89152624+StanFromIreland@users.noreply.github.com>
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
plashchynski pushed a commit to plashchynski/cpython that referenced this issue Mar 17, 2025
---------

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
seehwan pushed a commit to seehwan/cpython that referenced this issue Apr 16, 2025
---------

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation in the Doc dir topic-typing
Projects
None yet
Development

No branches or pull requests

2 participants
0