From 01193be241fa1cafa263658750ed6b999e4701dc Mon Sep 17 00:00:00 2001 From: SomberNight Date: Thu, 19 Jul 2018 13:55:05 +0200 Subject: [PATCH] logging: when not giving args to -v, log everything, as before --- electrum/commands.py | 2 +- electrum/util.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/electrum/commands.py b/electrum/commands.py index e9276d3bf..62d2ed6f4 100644 --- a/electrum/commands.py +++ b/electrum/commands.py @@ -831,7 +831,7 @@ def add_global_options(parser): group = parser.add_argument_group('global options') # const is for when no argument is given to verbosity # default is for when the flag is missing - group.add_argument("-v", "--verbosity", dest="verbosity", help="Set verbosity filter", default='', const='', nargs='?') + group.add_argument("-v", "--verbosity", dest="verbosity", help="Set verbosity filter", default='', const='*', nargs='?') group.add_argument("-D", "--dir", dest="electrum_path", help="electrum directory") group.add_argument("-P", "--portable", action="store_true", dest="portable", default=False, help="Use local 'electrum_data' directory") group.add_argument("-w", "--wallet", dest="wallet_path", help="wallet path") diff --git a/electrum/util.py b/electrum/util.py index aced2746b..485b34585 100644 --- a/electrum/util.py +++ b/electrum/util.py @@ -170,7 +170,7 @@ class PrintError(object): return self.__class__.__name__ def print_error(self, *msg): - if self.verbosity_filter in verbosity: + if self.verbosity_filter in verbosity or verbosity == '*': print_stderr("[%s]" % self.diagnostic_name(), *msg) def print_stderr(self, *msg): @@ -266,7 +266,7 @@ class DaemonThread(threading.Thread, PrintError): self.print_error("stopped") -verbosity = '' +verbosity = '*' def set_verbosity(b): global verbosity verbosity = b