From: Serge Rehbinder Date: Mon, 5 Sep 2016 08:33:08 +0000 (+0200) Subject: fix a bug of warning caused by paramiko in CentOS 6 X-Git-Tag: 5.0.0a1~149 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=687b1fe7273f7e3c651af943a02b7906740be243;p=tools%2Fsat.git fix a bug of warning caused by paramiko in CentOS 6 --- diff --git a/salomeTools.py b/salomeTools.py index 55a5a5c..02f1dab 100755 --- a/salomeTools.py +++ b/salomeTools.py @@ -22,6 +22,7 @@ # python imports import os import sys +import tempfile import imp import types import gettext @@ -143,7 +144,11 @@ class Sat(object): # Exception for the jobs command that requires the paramiko module if nameCmd == "jobs": try: + saveout = sys.stderr + ff = tempfile.TemporaryFile() + sys.stderr = ff import paramiko + sys.stderr = saveout except: continue