-
Notifications
You must be signed in to change notification settings - Fork 9
Open
Description
I add a finally function below to colose sftp connection, not sure if it still working
except (paramiko.BadHostKeyException, paramiko.AuthenticationException) as e:
raise AuthenticationError(str(e))
except socket.timeout as e:
raise TimeoutError(str(e))
except Exception as e:
if i == max_attempts - 1:
raise SshError(str(e))
finally:
if self.client:
self.client.close()
Metadata
Metadata
Assignees
Labels
No labels