diff options
author | Brian Coca <brian.coca+git@gmail.com> | 2016-10-10 07:04:02 +0200 |
---|---|---|
committer | Brian Coca <bcoca@users.noreply.github.com> | 2016-10-13 19:34:01 +0200 |
commit | 18d3e0533ffab71c42ea6c266ed435fb950cefd9 (patch) | |
tree | 9ebf007b5c0560c2232655fa204ca1d56c358498 /bin | |
parent | restored 'results' filters (diff) | |
download | ansible-18d3e0533ffab71c42ea6c266ed435fb950cefd9.tar.xz ansible-18d3e0533ffab71c42ea6c266ed435fb950cefd9.zip |
always log unexpected exceptions
Diffstat (limited to 'bin')
-rwxr-xr-x | bin/ansible | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/bin/ansible b/bin/ansible index bff20f74cb..3fa7091819 100755 --- a/bin/ansible +++ b/bin/ansible @@ -126,9 +126,11 @@ if __name__ == '__main__': have_cli_options = cli is not None and cli.options is not None display.error("Unexpected Exception: %s" % to_text(e), wrap_text=False) if not have_cli_options or have_cli_options and cli.options.verbosity > 2: - display.display(u"the full traceback was:\n\n%s" % to_text(traceback.format_exc())) + log_only = False else: display.display("to see the full traceback, use -vvv") + log_only = True + display.display(u"the full traceback was:\n\n%s" % to_text(traceback.format_exc()), log_only=log_only) exit_code = 250 finally: # Remove ansible tempdir |