From e430b8c2819e08a12bcb0af85449e498759d75e9 Mon Sep 17 00:00:00 2001 From: Dan Helfman Date: Sun, 10 Apr 2016 15:29:42 -0700 Subject: [PATCH] At verbosity zero, suppressing Borg check spew to stderr about "Checking segments". --- NEWS | 3 ++- atticmatic/backends/shared.py | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/NEWS b/NEWS index ddcfe78..321eb6f 100644 --- a/NEWS +++ b/NEWS @@ -2,9 +2,10 @@ * Fix for handling of spaces in source_directories which resulted in backup up everything. * Fix for broken links to Borg documentation. + * At verbosity zero, suppressing Borg check spew to stderr about "Checking segments". * Support for Borg --one-file-system. * Support for Borg create --umask. - * support for file globs in source_directories. + * Support for file globs in source_directories. 0.1.7 diff --git a/atticmatic/backends/shared.py b/atticmatic/backends/shared.py index 417a732..2fe6a5c 100644 --- a/atticmatic/backends/shared.py +++ b/atticmatic/backends/shared.py @@ -213,7 +213,7 @@ def check_archives(verbosity, repository, consistency_config, command): repository, ) + _make_check_flags(checks, check_last) + verbosity_flags - # The check command spews to stdout even without the verbose flag. Suppress it. + # The check command spews to stdout/stderr even without the verbose flag. Suppress it. stdout = None if verbosity_flags else open(os.devnull, 'w') - subprocess.check_call(full_command, stdout=stdout) + subprocess.check_call(full_command, stdout=stdout, stderr=subprocess.STDOUT)