Start cleaning up info field lists
This commit is contained in:
parent
33452b2e6c
commit
7df1ae9602
|
@ -52,8 +52,9 @@ class AgentSSH(object):
|
|||
no SSH agent was running (or it couldn't be contacted), an empty list
|
||||
will be returned.
|
||||
|
||||
:return: a list of keys available on the SSH agent
|
||||
:rtype: tuple of `.AgentKey`
|
||||
:return:
|
||||
a tuple of `.AgentKey` objects representing keys available on the
|
||||
SSH agent
|
||||
"""
|
||||
return self._keys
|
||||
|
||||
|
@ -235,7 +236,7 @@ class AgentClientProxy(object):
|
|||
|
||||
class AgentServerProxy(AgentSSH):
|
||||
"""
|
||||
:param t: transport used for SSH Agent communication forwarding
|
||||
:param .Transport t: Transport used for SSH Agent communication forwarding
|
||||
|
||||
:raises SSHException: mostly if we lost the agent
|
||||
"""
|
||||
|
@ -273,8 +274,8 @@ class AgentServerProxy(AgentSSH):
|
|||
"""
|
||||
Helper for the environnement under unix
|
||||
|
||||
:return: the SSH_AUTH_SOCK Environnement variables
|
||||
:rtype: dict
|
||||
:return:
|
||||
a dict containing the ``SSH_AUTH_SOCK`` environnement variables
|
||||
"""
|
||||
env = {}
|
||||
env['SSH_AUTH_SOCK'] = self._get_filename()
|
||||
|
|
|
@ -54,8 +54,7 @@ class BufferedPipe (object):
|
|||
buffer has been closed), the event will be set. When no data is
|
||||
ready, the event will be cleared.
|
||||
|
||||
:param event: the event to set/clear
|
||||
:type event: Event
|
||||
:param threading.Event event: the event to set/clear
|
||||
"""
|
||||
self._event = event
|
||||
if len(self._buffer) > 0:
|
||||
|
@ -68,8 +67,7 @@ class BufferedPipe (object):
|
|||
Feed new data into this pipe. This method is assumed to be called
|
||||
from a separate thread, so synchronization is done.
|
||||
|
||||
:param data: the data to add
|
||||
:type data: str
|
||||
:param data: the data to add, as a `str`
|
||||
"""
|
||||
self._lock.acquire()
|
||||
try:
|
||||
|
@ -86,9 +84,9 @@ class BufferedPipe (object):
|
|||
feeder. A ``False`` result does not mean that the feeder has closed;
|
||||
it means you may need to wait before more data arrives.
|
||||
|
||||
:return: ``True`` if a `read` call would immediately return at least
|
||||
one byte; ``False`` otherwise.
|
||||
:rtype: bool
|
||||
:return:
|
||||
``True`` if a `read` call would immediately return at least one
|
||||
byte; ``False`` otherwise.
|
||||
"""
|
||||
self._lock.acquire()
|
||||
try:
|
||||
|
@ -113,8 +111,7 @@ class BufferedPipe (object):
|
|||
:param int nbytes: maximum number of bytes to read
|
||||
:param float timeout:
|
||||
maximum seconds to wait (or ``None``, the default, to wait forever)
|
||||
:return: data
|
||||
:rtype: str
|
||||
:return: the read data, as a `str`
|
||||
|
||||
:raises PipeTimeout:
|
||||
if a timeout was specified and no data was ready before that
|
||||
|
@ -157,8 +154,9 @@ class BufferedPipe (object):
|
|||
"""
|
||||
Clear out the buffer and return all data that was in it.
|
||||
|
||||
:return: any data that was in the buffer prior to clearing it out
|
||||
:rtype: str
|
||||
:return:
|
||||
any data that was in the buffer prior to clearing it out, as a
|
||||
`str`
|
||||
"""
|
||||
self._lock.acquire()
|
||||
try:
|
||||
|
@ -188,8 +186,7 @@ class BufferedPipe (object):
|
|||
"""
|
||||
Return the number of bytes buffered.
|
||||
|
||||
:return: number of bytes buffered
|
||||
:rtype: int
|
||||
:return: number (`int`) of bytes buffered
|
||||
"""
|
||||
self._lock.acquire()
|
||||
try:
|
||||
|
|
|
@ -142,8 +142,8 @@ class Channel (object):
|
|||
:param height_pixels: height (in pixels) of the terminal screen
|
||||
:type height_pixels: int
|
||||
|
||||
:raises SSHException: if the request was rejected or the channel was
|
||||
closed
|
||||
:raises SSHException:
|
||||
if the request was rejected or the channel was closed
|
||||
"""
|
||||
if self.closed or self.eof_received or self.eof_sent or not self.active:
|
||||
raise SSHException('Channel is not open')
|
||||
|
|
Loading…
Reference in New Issue