Module Expr Str Import alias Import alias Import alias Import alias Import alias TryExcept body ImportFrom alias handlers ExceptHandler type NameLoad body ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam NameParam defaults body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Return BinOpMod Str TupleLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list decorator_list Assign NameStore CompareEq AttributeLoad NameLoad attr Str If NameLoad body Import alias orelse Import alias FunctionDef arguments args defaults vararg kwarg body Assign NameStore Dict If CompareIn Str NameLoad body Assign SubscriptStore NameLoad Index Str Call AttributeLoad NameLoad attr Str Return Call AttributeLoad Call NameLoad NameLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args defaults vararg kwarg body Expr Str Assign NameStore Call NameLoad NameLoad NameLoad If NameLoad body Assign NameStore Call AttributeLoad NameLoad attr Str If CompareIs NameLoad NameLoad body Assign NameStore SubscriptLoad NameLoad Index Num Raise Call NameLoad NameLoad NameLoad decorator_list If UnaryOpNot NameLoad body FunctionDef arguments args defaults vararg body Pass decorator_list ClassDef bases AttributeLoad NameLoad attr body If UnaryOpNot NameLoad body FunctionDef arguments args NameParam defaults vararg kwarg body If CompareGtE Call NameLoad NameLoad Num body Raise Call NameLoad Str Assign NameStore Call AttributeLoad NameLoad attr Str NameLoad FunctionDef arguments args defaults body Expr Call AttributeLoad NameLoad attr Num Num If NameLoad body Expr Call NameLoad NameLoad decorator_list Assign SubscriptStore NameLoad Index Str NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad NameLoad decorator_list If NameLoad body FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam defaults body If UnaryOpNot Call NameLoad NameLoad AttributeLoad NameLoad attr body Assign NameStore Call AttributeLoad NameLoad attr NameLoad If CompareIs NameLoad NameLoad body Assign NameStore Call AttributeLoad NameLoad attr If CompareNotIn NameLoad TupleLoad NameLoad NameLoad NameLoad body AugAssignBitOr AttributeStore NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call NameLoad NameLoad Assign AttributeStore NameLoad attr Call NameLoad NameLoad Assign AttributeStore NameLoad attr Call NameLoad NameLoad If NameLoad body AugAssignBitOr AttributeStore NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Str Str Assign NameStore BinOpAdd BinOpAdd NameLoad Str NameLoad Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr AugAssignBitOr NameStore AttributeLoad NameLoad attr AugAssignBitOr NameStore AttributeLoad NameLoad attr AugAssignBitOr NameStore AttributeLoad NameLoad attr Assign TupleStore NameStore NameStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad NameLoad Num NameLoad Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad If CompareIsNot NameLoad NameLoad body Expr Call AttributeLoad NameLoad attr If CompareIsNot NameLoad NameLoad body Expr Call AttributeLoad NameLoad attr If CompareIsNot NameLoad NameLoad body Expr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body Expr Str If NameLoad body If NameLoad body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Num orelse Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Num Assign AttributeStore NameLoad attr Num orelse If NameLoad body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr orelse Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Num decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults Num NameLoad body Expr Str If CompareIsNot AttributeLoad NameLoad attr NameLoad body Return AttributeLoad NameLoad attr If NameLoad body If CompareNotEq NameLoad Num body Assign NameStore BinOpMult NameLoad Num Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad If CompareEq NameLoad AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr NameLoad orelse Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr orelse If CompareEq NameLoad Num body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Return AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad While CompareLt Call AttributeLoad NameLoad attr BinOpSub BinOpAdd NameLoad NameLoad Num body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr If CompareNotEq NameLoad Num body Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad Return AttributeLoad NameLoad attr Assign NameStore BinOpAdd BinOpSub NameLoad Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Return AttributeLoad NameLoad attr decorator_list decorator_list
N/A N/A killableprocess - Subprocesses which can be reliably killed

This module is a subclass of the builtin "subprocess" module. It allows
processes that launch subprocesses to be reliably killed on Windows (via the Popen.kill() method.

It also adds a timeout argument to Wait() for a limited period of time before
forcefully killing the process.

Note: On Windows, this module requires Windows 2000 or higher (no support for
Windows 95, 98, or NT 4.0). It also requires ctypes, which is bundled with
Python 2.5+ or available from http://python.net/crew/theller/ctypes/
 N/A subprocess N/A sys N/A os N/A time N/A types N/A N/A subprocess CalledProcessError N/A N/A N/A ImportError N/A CalledProcessError N/A Exception N/A N/A This exception is raised when a process run by check_call() returns
        a non-zero exit status. The exit status will be stored in the
        returncode attribute. __init__ N/A N/A self returncode cmd N/A N/A N/A N/A self returncode returncode N/A N/A self cmd cmd N/A __str__ N/A N/A self N/A N/A N/A N/A Command '%s' returned non-zero exit status %d N/A N/A self cmd N/A self returncode N/A N/A N/A mswindows N/A N/A sys platform win32 N/A mswindows N/A N/A winprocess N/A N/A signal call N/A N/A N/A args kwargs N/A N/A waitargs N/A N/A N/A timeout kwargs N/A N/A N/A waitargs N/A timeout N/A N/A kwargs pop timeout N/A N/A N/A N/A Popen args kwargs wait waitargs N/A check_call N/A N/A N/A args kwargs N/A N/A Call a program with an optional timeout. If the program has a non-zero
    exit status, raises a CalledProcessError. N/A retcode N/A call args kwargs N/A retcode N/A N/A cmd N/A N/A kwargs get args N/A N/A cmd None N/A N/A cmd N/A args N/A 0 N/A N/A CalledProcessError retcode cmd N/A N/A N/A mswindows N/A DoNothing N/A N/A N/A args N/A N/A N/A Popen N/A N/A subprocess Popen N/A N/A N/A mswindows N/A __init__ N/A N/A self N/A args kwargs N/A N/A N/A N/A len args 7 N/A N/A N/A Exception Arguments preexec_fn and after must be passed by keyword. N/A real_preexec_fn N/A N/A kwargs pop preexec_fn None setpgid_preexec_fn N/A N/A N/A N/A N/A N/A N/A os setpgid 0 0 N/A real_preexec_fn N/A N/A N/A apply real_preexec_fn N/A N/A N/A kwargs N/A preexec_fn setpgid_preexec_fn N/A N/A N/A N/A subprocess Popen __init__ self args kwargs N/A N/A mswindows N/A _execute_child N/A N/A self args executable preexec_fn close_fds cwd env universal_newlines startupinfo creationflags shell p2cread p2cwrite c2pread c2pwrite errread errwrite N/A N/A N/A N/A N/A isinstance args N/A types StringTypes N/A N/A args N/A N/A subprocess list2cmdline args N/A N/A startupinfo None N/A N/A startupinfo N/A N/A winprocess STARTUPINFO N/A N/A None N/A p2cread c2pwrite errwrite N/A N/A N/A startupinfo dwFlags N/A winprocess STARTF_USESTDHANDLES N/A N/A startupinfo hStdInput N/A int p2cread N/A N/A startupinfo hStdOutput N/A int c2pwrite N/A N/A startupinfo hStdError N/A int errwrite N/A shell N/A N/A N/A startupinfo dwFlags N/A winprocess STARTF_USESHOWWINDOW N/A N/A startupinfo wShowWindow N/A winprocess SW_HIDE N/A comspec N/A N/A N/A os environ get COMSPEC cmd.exe N/A args N/A N/A comspec  /c  args N/A N/A self _job N/A N/A winprocess CreateJobObject N/A creationflags N/A winprocess CREATE_SUSPENDED N/A creationflags N/A winprocess CREATE_UNICODE_ENVIRONMENT N/A creationflags N/A winprocess CREATE_BREAKAWAY_FROM_JOB N/A N/A hp ht pid tid N/A N/A winprocess CreateProcess executable args None None 1 creationflags N/A N/A winprocess EnvironmentBlock env cwd startupinfo N/A N/A self _child_created True N/A N/A self _handle hp N/A N/A self _thread ht N/A N/A self pid pid N/A N/A N/A winprocess AssignProcessToJobObject N/A self _job hp N/A N/A N/A winprocess ResumeThread ht N/A N/A p2cread None N/A N/A N/A N/A p2cread Close N/A N/A c2pwrite None N/A N/A N/A N/A c2pwrite Close N/A N/A errwrite None N/A N/A N/A N/A errwrite Close N/A kill N/A N/A self group N/A True N/A N/A Kill the process. If group=True, all sub-processes will also be killed. N/A mswindows N/A N/A group N/A N/A N/A N/A winprocess TerminateJobObject N/A self _job 127 N/A N/A N/A N/A winprocess TerminateProcess N/A self _handle 127 N/A N/A self returncode 127 N/A N/A group N/A N/A N/A N/A os killpg N/A self pid N/A signal SIGKILL N/A N/A N/A N/A os kill N/A self pid N/A signal SIGKILL N/A N/A self returncode -9 N/A wait N/A N/A self timeout group N/A -1 True N/A N/A Wait for the process to terminate. Returns returncode attribute.
        If timeout seconds are reached and the process has not terminated,
        it will be forcefully killed. If timeout is -1, wait will not
        time out. N/A N/A N/A self returncode None N/A N/A N/A self returncode N/A mswindows N/A N/A N/A timeout -1 N/A N/A timeout N/A timeout 1000 N/A rc N/A N/A winprocess WaitForSingleObject N/A self _handle timeout N/A N/A rc N/A winprocess WAIT_TIMEOUT N/A N/A N/A N/A self kill group N/A N/A N/A self returncode N/A N/A winprocess GetExitCodeProcess N/A self _handle N/A N/A N/A timeout -1 N/A N/A N/A N/A N/A subprocess Popen wait self N/A N/A self returncode N/A starttime N/A N/A time time N/A oldsignal N/A N/A signal signal N/A signal SIGCHLD DoNothing N/A N/A N/A N/A time time N/A N/A starttime timeout 0.01 N/A N/A N/A pid sts N/A N/A os waitpid N/A self pid N/A os WNOHANG N/A N/A pid 0 N/A N/A N/A N/A self _handle_exitstatus sts N/A N/A N/A signal signal N/A signal SIGCHLD oldsignal N/A N/A self returncode N/A newtimeout N/A N/A timeout N/A N/A time time starttime N/A N/A N/A time sleep newtimeout N/A N/A N/A self kill group N/A N/A N/A signal signal N/A signal SIGCHLD oldsignal N/A N/A N/A N/A subprocess Popen wait self N/A N/A self returncode N/A N/A