ErrHelpParser¶
-
class
privex.helpers.common.
ErrHelpParser
(prog=None, usage=None, description=None, epilog=None, parents=[], formatter_class=<class 'argparse.HelpFormatter'>, prefix_chars='-', fromfile_prefix_chars=None, argument_default=None, conflict_handler='error', add_help=True, allow_abbrev=True)[source]¶ ErrHelpParser - Use this instead of
argparse.ArgumentParser
to automatically get full help output as well as the error message when arguments are invalid, instead of just an error message.>>> parser = ErrHelpParser(description='My command line app') >>> parser.add_argument('nums', metavar='N', type=int, nargs='+')
-
__init__
(prog=None, usage=None, description=None, epilog=None, parents=[], formatter_class=<class 'argparse.HelpFormatter'>, prefix_chars='-', fromfile_prefix_chars=None, argument_default=None, conflict_handler='error', add_help=True, allow_abbrev=True) Initialize self. See help(type(self)) for accurate signature.
-