Skip to content

Commit c587971

Browse files
output stderr when running ssh commands
1 parent 66ec45a commit c587971

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

shuffle-tools/1.2.0/src/app.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2632,6 +2632,11 @@ def run_ssh_command(self, host, port, user_name, private_key_file_id, password,
26322632

26332633
try:
26342634
stdin, stdout, stderr = ssh_client.exec_command(str(command))
2635+
2636+
stderr_ouput = stderr.read().decode(errors='ignore')
2637+
2638+
if stderr_ouput:
2639+
return {"success": "true", "message": stderr_ouput}
26352640
except Exception as e:
26362641
return {"success":"false","message":str(e)}
26372642

0 commit comments

Comments
 (0)