From b1b0c8d1c5f65a849f36eb3a0433e6f0cbc54e91 Mon Sep 17 00:00:00 2001 From: Nick Sweeting Date: Wed, 27 Mar 2019 15:33:12 -0400 Subject: [PATCH] show prettier failure output during link archiving --- archivebox/logs.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/archivebox/logs.py b/archivebox/logs.py index ccb9a10c..a4b83cfd 100644 --- a/archivebox/logs.py +++ b/archivebox/logs.py @@ -190,11 +190,11 @@ def log_archive_method_finished(result: ArchiveResult): # Collect and prefix output lines with indentation output_lines = [ - '{}Failed:{} {}{}'.format( - ANSI['red'], - result.output.__class__.__name__.replace('ArchiveError', ''), - result.output, - ANSI['reset'] + '{lightred}Failed:{reset}'.format(**ANSI), + ' {reset}{} {red}{}{reset}'.format( + result.output.__class__.__name__.replace('ArchiveError', ''), + result.output, + **ANSI, ), *hints, '{}Run to see full output:{}'.format(ANSI['lightred'], ANSI['reset']), @@ -206,3 +206,4 @@ def log_archive_method_finished(result: ArchiveResult): for line in output_lines if line )) + print()