self.ssh = paramiko.SSHClient()
self.ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy())
try:
self.ssh.connect(self.hostname, username=self.username, password=self.password)
except SSHException:
#do something
我想知道在尝试连接到 ssh 服务器时如何处理 paramiko 引发的错误?