Skip to content

add subprocess.STARTUPINFO and some associated constants #2041

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 12, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 31 additions & 1 deletion stdlib/3/subprocess.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -371,4 +371,34 @@ def getoutput(cmd: _TXT) -> str: ...

def list2cmdline(seq: Sequence[str]) -> str: ... # undocumented

# Windows-only: STARTUPINFO etc.
if sys.platform == 'win32':
class STARTUPINFO:
if sys.version_info >= (3, 7):
def __init__(self, *, dwFlags: int = ..., hStdInput: Optional[Any] = ..., hStdOutput: Optional[Any] = ..., hStdError: Optional[Any] = ..., wShowWindow: int = ..., lpAttributeList: Optional[Mapping[str, Any]] = ...) -> None: ...
dwFlags: int
hStdInput: Optional[Any]
hStdOutput: Optional[Any]
hStdError: Optional[Any]
wShowWindow: int
if sys.version_info >= (3, 7):
lpAttributeList: Mapping[str, Any]

STD_INPUT_HANDLE: Any
STD_OUTPUT_HANDLE: Any
STD_ERROR_HANDLE: Any
SW_HIDE: int
STARTF_USESTDHANDLES: int
STARTF_USESHOWWINDOW: int
CREATE_NEW_CONSOLE: int
CREATE_NEW_PROCESS_GROUP: int
if sys.version_info >= (3, 7):
ABOVE_NORMAL_PRIORITY_CLASS: int
BELOW_NORMAL_PRIORITY_CLASS: int
HIGH_PRIORITY_CLASS: int
IDLE_PRIORITY_CLASS: int
NORMAL_PRIORITY_CLASS: int
REALTIME_PRIORITY_CLASS: int
CREATE_NO_WINDOW: int
DETACHED_PROCESS: int
CREATE_DEFAULT_ERROR_MODE: int
CREATE_BREAKAWAY_FROM_JOB: int