mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-09 05:24:52 +08:00
Add timeout argument to Popen communicate (#423)
This was added in Python 3.3
This commit is contained in:
committed by
Matthias Kramm
parent
07bf49f55a
commit
51a519b358
@@ -2,6 +2,7 @@
|
||||
|
||||
# Based on http://docs.python.org/3.2/library/subprocess.html
|
||||
|
||||
import sys
|
||||
from typing import Sequence, Any, Mapping, Callable, Tuple, IO, Optional, Union
|
||||
|
||||
# Same args as Popen.__init__
|
||||
@@ -101,7 +102,10 @@ class Popen:
|
||||
def poll(self) -> int: ...
|
||||
def wait(self) -> int: ...
|
||||
# Return str/bytes
|
||||
def communicate(self, input=...) -> Tuple[Any, Any]: ...
|
||||
if sys.version_info >= (3, 3):
|
||||
def communicate(self, input=..., timeout: float = ...) -> Tuple[Any, Any]: ...
|
||||
else:
|
||||
def communicate(self, input=...) -> Tuple[Any, Any]: ...
|
||||
def send_signal(self, signal: int) -> None: ...
|
||||
def terminate(self) -> None: ...
|
||||
def kill(self) -> None: ...
|
||||
|
||||
Reference in New Issue
Block a user