mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-16 08:47:39 +08:00
input argument to Process.communicate is Optional (#894)
The code for this method starts as follows:
```
@coroutine
def communicate(self, input=None):
if input is not None:
stdin = self._feed_stdin(input)
```
This commit is contained in:
committed by
Guido van Rossum
parent
6d1edb285d
commit
9a1e8452a3
@@ -3,7 +3,7 @@ from asyncio import protocols
|
||||
from asyncio import streams
|
||||
from asyncio import transports
|
||||
from asyncio.coroutines import coroutine
|
||||
from typing import Any, AnyStr, Tuple, Union
|
||||
from typing import Any, AnyStr, Optional, Tuple, Union
|
||||
|
||||
__all__ = ... # type: str
|
||||
|
||||
@@ -33,7 +33,7 @@ class Process:
|
||||
def terminate(self) -> None: ...
|
||||
def kill(self) -> None: ...
|
||||
@coroutine
|
||||
def communicate(self, input: bytes = ...) -> Tuple[bytes, bytes]: ...
|
||||
def communicate(self, input: Optional[bytes] = ...) -> Tuple[bytes, bytes]: ...
|
||||
|
||||
|
||||
@coroutine
|
||||
|
||||
Reference in New Issue
Block a user