(self, timeout=None)
Poll the running process to update the output buffer and the status.

        :param timeout: Override the default WSMan timeout when polling the
        process.
Poll the running process to update the output buffer and the status.
Poll the running process to update the output buffer and the status .
def poll_invoke(self, timeout=None):
        """
        Poll the running process to update the output buffer and the status.

        :param timeout: Override the default WSMan timeout when polling the
        process.
        """
        try:
            self.state, self.rc, buffer = self.shell.receive('stdout stderr',
                                                             self.id,
                                                             timeout=timeout)
        except WSManFaultError as exc:
            # if a command exceeds the OperationTimeout set, we will get
            # a WSManFaultError with the code 2150858793. We ignore this
            # as it just meant no output during that operation.
            if exc.code == 2150858793:
                pass
            else:
                raise exc
        else:
            self.stdout += buffer['stdout']
            self.stderr += buffer['stderr']
def poll_invoke ( self , timeout = None ) : try : self . state , self . rc , buffer = self . shell . receive ( 'stdout stderr' , self . id , timeout = timeout ) except WSManFaultError as exc : # if a command exceeds the OperationTimeout set, we will get # a WSManFaultError with the code 2150858793. We ignore this # as it just meant no output during that operation. if exc . code == 2150858793 : pass else : raise exc else : self . stdout += buffer [ 'stdout' ] self . stderr += buffer [ 'stderr' ]