Thanks to visit codestin.com
Credit goes to github.com

Skip to content

bpo-37814: Document the empty tuple type annotation syntax #15208

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

Merged
merged 2 commits into from
Aug 13, 2019
Merged

bpo-37814: Document the empty tuple type annotation syntax #15208

merged 2 commits into from
Aug 13, 2019

Conversation

keysmashes
Copy link
Contributor

@keysmashes keysmashes commented Aug 11, 2019

https://bugs.python.org/issue37814:

The empty tuple syntax in type annotations, Tuple[()], is not obvious from the examples given in the documentation (I naively expected Tuple[] to work); it has been documented in PEP 484 and in mypy, but not in the documentation for the typing module.

https://bugs.python.org/issue37814

Automerge-Triggered-By: @gvanrossum

@the-knights-who-say-ni
Copy link

Hello, and thanks for your contribution!

I'm a bot set up to make sure that the project can legally accept your contribution by verifying you have signed the PSF contributor agreement (CLA).

Our records indicate we have not received your CLA. For legal reasons we need you to sign this before we can look at your contribution. Please follow the steps outlined in the CPython devguide to rectify this issue.

If you have recently signed the CLA, please wait at least one business day
before our records are updated.

You can check yourself to see if the CLA has been received.

Thanks again for your contribution, we look forward to reviewing it!

@bedevere-bot bedevere-bot added docs Documentation in the Doc dir awaiting review labels Aug 11, 2019
Copy link
Member

@gvanrossum gvanrossum left a comment

Choose a reason for hiding this comment

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

Can you please sign the CLA so we can proceed, and adjust the text as I suggested?

Copy link
Member

@gvanrossum gvanrossum left a comment

Choose a reason for hiding this comment

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

Thanks! All good now. How about signing the CLA?

@miss-islington
Copy link
Contributor

Thanks @anowlcalledjosh for the PR 🌮🎉.. I'm working now to backport this PR to: 3.7.
🐍🍒⛏🤖

@miss-islington
Copy link
Contributor

Thanks @anowlcalledjosh for the PR 🌮🎉.. I'm working now to backport this PR to: 3.8.
🐍🍒⛏🤖

@miss-islington
Copy link
Contributor

Sorry @anowlcalledjosh, I had trouble checking out the 3.7 backport branch.
Please backport using cherry_picker on command line.
cherry_picker 8a784af750fa82c8355903309e5089eb2b60c16b 3.7

@miss-islington miss-islington self-assigned this Aug 13, 2019
miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Aug 13, 2019
…15208)

https://bugs.python.org/issue37814:

> The empty tuple syntax in type annotations, `Tuple[()]`, is not obvious from the examples given in the documentation (I naively expected `Tuple[]` to work); it has been documented in PEP 484 and in mypy, but not in the documentation for the typing module.

https://bugs.python.org/issue37814
(cherry picked from commit 8a784af)

Co-authored-by: Josh Holland <[email protected]>
@bedevere-bot
Copy link

GH-15261 is a backport of this pull request to the 3.8 branch.

miss-islington added a commit that referenced this pull request Aug 13, 2019
https://bugs.python.org/issue37814:

> The empty tuple syntax in type annotations, `Tuple[()]`, is not obvious from the examples given in the documentation (I naively expected `Tuple[]` to work); it has been documented in PEP 484 and in mypy, but not in the documentation for the typing module.

https://bugs.python.org/issue37814
(cherry picked from commit 8a784af)

Co-authored-by: Josh Holland <[email protected]>
@bedevere-bot
Copy link

GH-15262 is a backport of this pull request to the 3.7 branch.

miss-islington pushed a commit that referenced this pull request Aug 13, 2019
…15208) (GH-15262)

https://bugs.python.org/issue37814:

> The empty tuple syntax in type annotations, `Tuple[()]`, is not obvious from the examples given in the documentation (I naively expected `Tuple[]` to work); it has been documented in PEP 484 and in mypy, but not in the documentation for the typing module.

https://bugs.python.org/issue37814
(cherry picked from commit 8a784af)

Co-authored-by: Josh Holland <[email protected]>





https://bugs.python.org/issue37814



Automerge-Triggered-By: @gvanrossum
@keysmashes keysmashes deleted the empty-tuple-doc branch August 13, 2019 20:15
lisroach pushed a commit to lisroach/cpython that referenced this pull request Sep 10, 2019
…15208)

https://bugs.python.org/issue37814:

> The empty tuple syntax in type annotations, `Tuple[()]`, is not obvious from the examples given in the documentation (I naively expected `Tuple[]` to work); it has been documented in PEP 484 and in mypy, but not in the documentation for the typing module.


https://bugs.python.org/issue37814
DinoV pushed a commit to DinoV/cpython that referenced this pull request Jan 14, 2020
…15208)

https://bugs.python.org/issue37814:

> The empty tuple syntax in type annotations, `Tuple[()]`, is not obvious from the examples given in the documentation (I naively expected `Tuple[]` to work); it has been documented in PEP 484 and in mypy, but not in the documentation for the typing module.


https://bugs.python.org/issue37814
websurfer5 pushed a commit to websurfer5/cpython that referenced this pull request Jul 20, 2020
…15208)

https://bugs.python.org/issue37814:

> The empty tuple syntax in type annotations, `Tuple[()]`, is not obvious from the examples given in the documentation (I naively expected `Tuple[]` to work); it has been documented in PEP 484 and in mypy, but not in the documentation for the typing module.


https://bugs.python.org/issue37814
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 skip news
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants