Skip to content
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

PEP 563 and annotations __future__ mandatory version #85486

Closed
wyz23x2 mannequin opened this issue Jul 16, 2020 · 12 comments
Closed

PEP 563 and annotations __future__ mandatory version #85486

wyz23x2 mannequin opened this issue Jul 16, 2020 · 12 comments
Labels
3.8 only security fixes 3.9 only security fixes 3.10 only security fixes docs Documentation in the Doc dir stdlib Python modules in the Lib dir

Comments

@wyz23x2
Copy link
Mannequin

wyz23x2 mannequin commented Jul 16, 2020

BPO 41314
Nosy @gvanrossum, @terryjreedy, @ned-deily, @ambv, @YoSTEALTH, @miss-islington, @wyz23x2
PRs
  • bpo-41314: fixed annotations __future__ version #21616
  • [3.9] bpo-41314: fixed annotations __future__ version (GH-21616) #21620
  • [3.8] bpo-41314: fixed annotations __future__ version (GH-21616) #21621
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = None
    closed_at = <Date 2020-07-25.22:12:13.148>
    created_at = <Date 2020-07-16.10:34:24.413>
    labels = ['3.8', 'library', '3.9', '3.10', 'docs']
    title = 'PEP 563 and annotations __future__ mandatory version'
    updated_at = <Date 2020-07-25.22:12:13.147>
    user = 'https://github.com/wyz23x2'

    bugs.python.org fields:

    activity = <Date 2020-07-25.22:12:13.147>
    actor = 'gvanrossum'
    assignee = 'docs@python'
    closed = True
    closed_date = <Date 2020-07-25.22:12:13.148>
    closer = 'gvanrossum'
    components = ['Documentation', 'Library (Lib)']
    creation = <Date 2020-07-16.10:34:24.413>
    creator = 'wyz23x2'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 41314
    keywords = ['patch']
    message_count = 12.0
    messages = ['373753', '373872', '373907', '374271', '374272', '374283', '374284', '374285', '374287', '374289', '374290', '374292']
    nosy_count = 8.0
    nosy_names = ['gvanrossum', 'terry.reedy', 'ned.deily', 'docs@python', 'lukasz.langa', 'YoSTEALTH', 'miss-islington', 'wyz23x2']
    pr_nums = ['21616', '21620', '21621']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = None
    url = 'https://bugs.python.org/issue41314'
    versions = ['Python 3.8', 'Python 3.9', 'Python 3.10']

    @wyz23x2
    Copy link
    Mannequin Author

    wyz23x2 mannequin commented Jul 16, 2020

    In https://docs.python.org/3/library/__future__.html:
    annotations | 3.7.0b1 | *4.0* | PEP-563: Postponed evaluation of annotations

    In PEP-563:
    Starting with Python 3.7, a __future__ import is required to use the described functionality. No warnings are raised.

    In Python *3.10* this will become the default behavior. Use of annotations incompatible with this PEP is no longer supported.

    Python 4.0 or 3.10? Not clear.

    @wyz23x2 wyz23x2 mannequin added docs Documentation in the Doc dir 3.7 (EOL) end of life 3.10 only security fixes labels Jul 16, 2020
    @wyz23x2 wyz23x2 mannequin assigned docspython Jul 16, 2020
    @wyz23x2 wyz23x2 mannequin added docs Documentation in the Doc dir 3.7 (EOL) end of life 3.10 only security fixes labels Jul 16, 2020
    @wyz23x2 wyz23x2 mannequin assigned docspython Jul 16, 2020
    @wyz23x2 wyz23x2 mannequin added stdlib Python modules in the Lib dir labels Jul 18, 2020
    @terryjreedy
    Copy link
    Member

    The PEP was accepted apparently by Guido sometime after the second posting 21-Nov-2017. Guido added the annotations entry to __future__ on 1/26/2018 with the 'mandatory' version changed to 4.0, which means 'some indefinite undecided future version'. I consider '4.0' to the intentional and definitive until Guido or Lucasz say otherwise.

    When PEP implementations differ from the PEP, we do not usually go back and revise the PEP. The implementation rules unless clearly buggy.

    @terryjreedy terryjreedy added 3.8 only security fixes 3.9 only security fixes and removed 3.7 (EOL) end of life labels Jul 18, 2020
    @terryjreedy terryjreedy changed the title __future__ doc and PEP 563 conflict PEP 563 and annotations __future__ mandatory version Jul 18, 2020
    @terryjreedy terryjreedy added 3.8 only security fixes 3.9 only security fixes and removed 3.7 (EOL) end of life labels Jul 18, 2020
    @terryjreedy terryjreedy changed the title __future__ doc and PEP 563 conflict PEP 563 and annotations __future__ mandatory version Jul 18, 2020
    @gvanrossum
    Copy link
    Member

    The PEP now says 3.10, so the docs for __future__ should be fixed.

    @gvanrossum gvanrossum reopened this Jul 18, 2020
    @gvanrossum gvanrossum reopened this Jul 18, 2020
    @wyz23x2
    Copy link
    Mannequin Author

    wyz23x2 mannequin commented Jul 25, 2020

    Ping?

    @gvanrossum
    Copy link
    Member

    Waiting for someone to submit a PR.

    @YoSTEALTH YoSTEALTH mannequin added 3.7 (EOL) end of life labels Jul 25, 2020
    @miss-islington
    Copy link
    Contributor

    New changeset 0028c14 by YoSTEALTH in branch 'master':
    bpo-41314: fixed annotations __future__ version (GH-21616)
    0028c14

    @gvanrossum
    Copy link
    Member

    @ned This will need your assistance to merge the 3.7 backport IIUC.

    @gvanrossum
    Copy link
    Member

    Never mind, Miss Islington failed to backport to 3.7, so let's forget about that.

    @gvanrossum gvanrossum removed 3.7 (EOL) end of life labels Jul 25, 2020
    @YoSTEALTH
    Copy link
    Mannequin

    YoSTEALTH mannequin commented Jul 25, 2020

    @gvanrossum I found couple of odd places where 4.0 is mentioned like https://docs.python.org/3/library/array.html for example, should a new issue be created? I am not sure how many more there are.

    @miss-islington
    Copy link
    Contributor

    New changeset b99f770 by Miss Islington (bot) in branch '3.8':
    bpo-41314: fixed annotations __future__ version (GH-21616)
    b99f770

    @miss-islington
    Copy link
    Contributor

    New changeset fdc91c2 by Miss Islington (bot) in branch '3.9':
    bpo-41314: fixed annotations __future__ version (GH-21616)
    fdc91c2

    @gvanrossum
    Copy link
    Member

    In general, "4.0" means "never", and for some deprecations that seems totally appropriate. I wouldn't worry about it. I'm closing this issue now that all three PRs have been merged. Thanks for your contribution!

    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    3.8 only security fixes 3.9 only security fixes 3.10 only security fixes docs Documentation in the Doc dir stdlib Python modules in the Lib dir
    Projects
    None yet
    Development

    No branches or pull requests

    3 participants