Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 662388

Summary: sys-apps/portage: Add asyncio.create_subprocess_exec support for python2
Product: Portage Development Reporter: Zac Medico <zmedico>
Component: CoreAssignee: Portage team <dev-portage>
Status: RESOLVED FIXED    
Severity: normal Keywords: InVCS
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: All   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 658182, 659322    

Description Zac Medico gentoo-dev 2018-07-29 03:14:40 UTC
The asyncio.create_subprocess_exec function is essential for using subprocesses in coroutines, so add support to do this for python2. This paves the way for extensive use of coroutines in portage, since coroutines are well-suited for many portage tasks that involve subprocesses. I'll be posting a patch soon.
Comment 2 Larry the Git Cow gentoo-dev 2018-08-06 05:01:22 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/proj/portage.git/commit/?id=6b4252d3a0f12808a5bcce888b7f68e1f84b5301

commit 6b4252d3a0f12808a5bcce888b7f68e1f84b5301
Author:     Zac Medico <zmedico@gentoo.org>
AuthorDate: 2018-07-28 21:22:42 +0000
Commit:     Zac Medico <zmedico@gentoo.org>
CommitDate: 2018-08-06 04:38:41 +0000

    Add asyncio.create_subprocess_exec support for python2 (bug 662388)
    
    The asyncio.create_subprocess_exec function is essential for
    using subprocesses in coroutines, so add support to do this
    for python2. This paves the way for extensive use of coroutines
    in portage, since coroutines are well-suited for many portage
    tasks that involve subprocesses.
    
    Bug: https://bugs.gentoo.org/662388

 .../util/futures/asyncio/test_subprocess_exec.py   | 184 ++++++---------------
 lib/portage/util/futures/_asyncio/__init__.py      |  53 ++++++
 lib/portage/util/futures/_asyncio/process.py       | 107 ++++++++++++
 lib/portage/util/futures/_asyncio/streams.py       |  96 +++++++++++
 lib/portage/util/futures/compat_coroutine.py       |   6 +-
 5 files changed, 315 insertions(+), 131 deletions(-)