Kaydet (Commit) 1285cbb7 authored tarafından Fatih Aşıcı's avatar Fatih Aşıcı

Do not show traceback for handled pisi errors

üst 757e7d97
......@@ -43,7 +43,6 @@ def handle_exception(exception, value, tb):
exit()
elif isinstance(value, pisi.Error):
ui.error(_("Program terminated."))
show_traceback = ctx.get_option('debug')
elif isinstance(value, pisi.Exception):
show_traceback = True
ui.error(_("Unhandled internal exception.\n"
......@@ -64,9 +63,8 @@ def handle_exception(exception, value, tb):
if show_traceback:
ui.info(_("\nTraceback:"))
traceback.print_tb(tb)
else:
if not exception is pisi.Error:
ui.info(_("Use --debug to see a traceback."))
elif not isinstance(value, pisi.Error):
ui.info(_("Use --debug to see a traceback."))
exit()
......
......@@ -405,7 +405,7 @@ class Install(AtomicOperation):
if missing_old_files:
ctx.ui.warning(_("Unable to relocate following files. Reinstallation of this package is strongly recommended."))
for f in sorted(missing_old_files):
ctx.ui.warning("\t- %s" % f)
ctx.ui.warning(" - %s" % f)
# remove left over files from the old package.
def clean_leftovers():
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment