You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[BUG] - SSH exec_command gets stuck while waiting for threading Event #2599
If you're connecting as a client, which SSH server are you connecting to?
No response
If you're using paramiko as part of another tool, which tool/version?
No response
Expected/desired behavior
In some of my applications that have long running SSH connections, sometimes the exec_command() function call in SSHClient gets stuck indefinitely, causing the entire process to get blocked.
I went through the code and found that exec_command uses self.event.wait() directly without passing the timeout parameter, which is the root cause for this issue. Code reference mentioned below:
We should be passing timeout here as well to avoid getting stuck indefinitely. Python threading library already exposes a timeout parameter which should be used here.
Activity