mirror of https://github.com/docker/docker-py.git
flake8 fixes
Signed-off-by: aiordache <anca.iordache@docker.com>
This commit is contained in:
parent
b72988bc87
commit
593d0c97d3
|
@ -97,14 +97,13 @@ class SSHSocket(socket.socket):
|
|||
self.proc.stdin.flush()
|
||||
return len(msg)
|
||||
|
||||
|
||||
def recv(self):
|
||||
if not self.proc:
|
||||
raise Exception('SSH subprocess not initiated.'
|
||||
'connect() must be called first.')
|
||||
response = self.proc.stdout.read()
|
||||
return response
|
||||
|
||||
|
||||
def makefile(self, mode):
|
||||
if not self.proc or self.proc.stdout.closed:
|
||||
buf = io.BytesIO()
|
||||
|
@ -119,6 +118,7 @@ class SSHSocket(socket.socket):
|
|||
self.proc.stdin.flush()
|
||||
self.proc.terminate()
|
||||
|
||||
|
||||
class SSHConnection(httplib.HTTPConnection, object):
|
||||
def __init__(self, ssh_transport=None, timeout=60, host=None):
|
||||
super(SSHConnection, self).__init__(
|
||||
|
@ -153,7 +153,7 @@ class SSHConnectionPool(urllib3.connectionpool.HTTPConnectionPool):
|
|||
self.ssh_transport = ssh_client.get_transport()
|
||||
self.timeout = timeout
|
||||
self.host = host
|
||||
|
||||
|
||||
# self.base_url = six.moves.urllib_parse.urlparse(host)
|
||||
self.port = None
|
||||
if ':' in host:
|
||||
|
|
|
@ -85,7 +85,10 @@ class BaseAPIIntegrationTest(BaseIntegrationTest):
|
|||
@staticmethod
|
||||
def get_client_instance():
|
||||
return docker.APIClient(
|
||||
version=TEST_API_VERSION, timeout=60, use_ssh_client=True, **kwargs_from_env()
|
||||
version=TEST_API_VERSION,
|
||||
timeout=60,
|
||||
use_ssh_client=True,
|
||||
**kwargs_from_env()
|
||||
)
|
||||
|
||||
@staticmethod
|
||||
|
|
Loading…
Reference in New Issue