file transfer via ssh was fixed about exception throwing

This commit is contained in:
Volkan Şahin 2016-05-17 12:29:51 +03:00
parent bff63ae806
commit 7d22232c1c

View file

@ -43,6 +43,7 @@ class FileTransfer(object):
self.logger.debug('[FileTransfer] File was downloaded to {} from {}'.format(local_path, remote_path))
except Exception as e:
self.logger.error('[FileTransfer] A problem occurred while downloading file. Exception message: {}'.format(str(e)))
raise
finally:
self.connection.close()
self.logger.debug('[FileTransfer] Connection is closed successfully')