mirror of
https://github.com/python/cpython.git
synced 2025-08-04 00:48:58 +00:00
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
This commit is contained in:
parent
e10920f0d1
commit
2dba23af71
4 changed files with 23 additions and 7 deletions
|
@ -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:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue