diff options
author | Victor Stinner <victor.stinner@gmail.com> | 2014-07-02 22:59:00 (GMT) |
---|---|---|
committer | Victor Stinner <victor.stinner@gmail.com> | 2014-07-02 22:59:00 (GMT) |
commit | 2dba23af7145f3edc608dc16209e6ead38c0f6c8 (patch) | |
tree | 0eec0e78f459221e1c2d269351d7b9e4aa5755ff /Lib/asyncio/unix_events.py | |
parent | e10920f0d1009ea33ce4b35b015a928b33a80867 (diff) | |
download | cpython-2dba23af7145f3edc608dc16209e6ead38c0f6c8.zip cpython-2dba23af7145f3edc608dc16209e6ead38c0f6c8.tar.gz cpython-2dba23af7145f3edc608dc16209e6ead38c0f6c8.tar.bz2 |
asyncio: sync with Tulip
* _UnixSubprocessTransport: fix file mode of stdin. Open stdin in write mode,
not in read mode
* Examples: close the event loop at exit
* More reliable CoroWrapper.__del__. If the constructor is interrupted by
KeyboardInterrupt or the coroutine objet is destroyed lately, some the
_source_traceback attribute doesn't exist anymore.
* repr(Task): include also the future the task is waiting for
Diffstat (limited to 'Lib/asyncio/unix_events.py')
-rw-r--r-- | Lib/asyncio/unix_events.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/asyncio/unix_events.py b/Lib/asyncio/unix_events.py index 1cb70ff..5f728b5 100644 --- a/Lib/asyncio/unix_events.py +++ b/Lib/asyncio/unix_events.py @@ -494,7 +494,7 @@ class _UnixSubprocessTransport(base_subprocess.BaseSubprocessTransport): universal_newlines=False, bufsize=bufsize, **kwargs) if stdin_w is not None: stdin.close() - self._proc.stdin = open(stdin_w.detach(), 'rb', buffering=bufsize) + self._proc.stdin = open(stdin_w.detach(), 'wb', buffering=bufsize) class AbstractChildWatcher: |