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

Document asyncio.futures.wrap_future() #68973

Closed
agronholm mannequin opened this issue Aug 3, 2015 · 2 comments
Closed

Document asyncio.futures.wrap_future() #68973

agronholm mannequin opened this issue Aug 3, 2015 · 2 comments
Labels
docs Documentation in the Doc dir type-feature A feature request or enhancement

Comments

@agronholm
Copy link
Mannequin

agronholm mannequin commented Aug 3, 2015

BPO 24785
Nosy @agronholm, @berkerpeksag, @1st1
Superseder
  • bpo-24755: asyncio.wrap_future undocumented
  • 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 2015-08-03.12:04:02.863>
    created_at = <Date 2015-08-03.11:44:43.192>
    labels = ['type-feature', 'docs']
    title = 'Document asyncio.futures.wrap_future()'
    updated_at = <Date 2015-08-03.12:31:27.517>
    user = 'https://github.com/agronholm'

    bugs.python.org fields:

    activity = <Date 2015-08-03.12:31:27.517>
    actor = 'yselivanov'
    assignee = 'docs@python'
    closed = True
    closed_date = <Date 2015-08-03.12:04:02.863>
    closer = 'berker.peksag'
    components = ['Documentation']
    creation = <Date 2015-08-03.11:44:43.192>
    creator = 'alex.gronholm'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 24785
    keywords = []
    message_count = 2.0
    messages = ['247924', '247926']
    nosy_count = 4.0
    nosy_names = ['alex.gronholm', 'docs@python', 'berker.peksag', 'yselivanov']
    pr_nums = []
    priority = 'normal'
    resolution = 'duplicate'
    stage = 'resolved'
    status = 'closed'
    superseder = '24755'
    type = 'enhancement'
    url = 'https://bugs.python.org/issue24785'
    versions = ['Python 3.5']

    @agronholm
    Copy link
    Mannequin Author

    agronholm mannequin commented Aug 3, 2015

    Since Python 3.5 will not support awaiting for concurrent.futures.Futures natively, one has to use the asyncio.futures.wrap_future() function in coroutines like this:

    async def foo():
        await wrap_future(executor.submit(...))

    The wrap_future() function is, however, not mentioned in the asyncio documentation. It should be, in order for the standard library to provide the above crutch until proper support arrives in 3.6.

    @agronholm agronholm mannequin assigned docspython Aug 3, 2015
    @agronholm agronholm mannequin added docs Documentation in the Doc dir type-feature A feature request or enhancement labels Aug 3, 2015
    @berkerpeksag
    Copy link
    Member

    This is a duplicate of bpo-24755.

    @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
    docs Documentation in the Doc dir type-feature A feature request or enhancement
    Projects
    None yet
    Development

    No branches or pull requests

    1 participant