def __init__(self, cmd, timeout, ssh_connect_timeout, stdout=None, stderr=None):
        """
        :param stdout: Stdout which was consumed until the timeout occured.
        :type stdout: ``str``

        :param stdout: Stderr which was consumed until the timeout occured.
        :type stderr: ``str``
        """
        self.cmd = cmd
        self.timeout = timeout
        self.ssh_connect_timeout = ssh_connect_timeout
        self.stdout = stdout
        self.stderr = stderr
        self.message = (
            "Command didn't finish in %s seconds or the SSH connection "
            "did not succeed in %s seconds" % (timeout, ssh_connect_timeout)
        )
        super(SSHCommandTimeoutError, self).__init__(self.message)

        :param stdout: Stdout which was consumed until the timeout occured.
        :type stdout: ``str``

        :param stdout: Stderr which was consumed until the timeout occured.
        :type stderr: ``str``
        
st2common/st2common/runners/paramiko_ssh.py