Commit 6e466d47 authored by Robin Obůrka's avatar Robin Obůrka

argparse: Add support for verbose mode in our logger and argparser

parent fc8655cb
import argparse
import logging
class EnableVerbose(argparse.Action):
def __call__(self, parser, namespace, values, option_string=None):
root = logging.getLogger()
root.setLevel(logging.DEBUG)
def get_arg_parser():
......@@ -15,4 +22,9 @@ def get_arg_parser():
action='store_true',
help='Disable IPv6 mode of ZMQ sockets'
)
parser.add_argument('-v', '--verbose',
nargs=0,
action=EnableVerbose,
help="Enables debug mode in logger"
)
return parser
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