summaryrefslogtreecommitdiffstats
path: root/ipaserver/install/installutils.py
diff options
context:
space:
mode:
authorAna Krivokapic <akrivoka@redhat.com>2013-06-17 15:04:50 +0200
committerPetr Viktorin <pviktori@redhat.com>2013-06-24 14:23:09 +0200
commit2775dec3bec3499c69de60d5bb581ffad7615cef (patch)
tree69726f1bdb31e8030bcb70d4bc3e62ed84c249eb /ipaserver/install/installutils.py
parente5117bd995aa10aab59f487058b4a57c8b695be9 (diff)
downloadfreeipa-2775dec3bec3499c69de60d5bb581ffad7615cef.tar.gz
freeipa-2775dec3bec3499c69de60d5bb581ffad7615cef.tar.xz
freeipa-2775dec3bec3499c69de60d5bb581ffad7615cef.zip
Do not display traceback to user
Logging tracebacks at the INFO level caused them to be displayed to user on the command line. Change the log level to DEBUG, so that tracebacks are not visible to user. https://fedorahosted.org/freeipa/ticket/3704
Diffstat (limited to 'ipaserver/install/installutils.py')
-rw-r--r--ipaserver/install/installutils.py9
1 files changed, 4 insertions, 5 deletions
diff --git a/ipaserver/install/installutils.py b/ipaserver/install/installutils.py
index 830a78a8b..278240f1e 100644
--- a/ipaserver/install/installutils.py
+++ b/ipaserver/install/installutils.py
@@ -618,14 +618,13 @@ def run_script(main_function, operation_name, log_file_name=None,
root_logger.info('The %s command was successful',
operation_name)
else:
- # Log at the INFO level, which is not output to the console
+ # Log at the DEBUG level, which is not output to the console
# (unless in debug/verbose mode), but is written to a logfile
# if one is open.
tb = sys.exc_info()[2]
- root_logger.info('\n'.join(traceback.format_tb(tb)))
- root_logger.info('The %s command failed, exception: %s: %s',
- operation_name, type(e).__name__, e)
- exception = e
+ root_logger.debug('\n'.join(traceback.format_tb(tb)))
+ root_logger.debug('The %s command failed, exception: %s: %s',
+ operation_name, type(e).__name__, e)
if fail_message and not isinstance(e, SystemExit):
print fail_message
raise