Nikita Sobolev <m...@sobolevn.me> added the comment:
Hi! >From your description it is not clear how exactly you create your subcommand. >From my experience, it works. Demo: ``` import argparse parser = argparse.ArgumentParser(description='Process some integers.') subparsers = parser.add_subparsers() # create the parser for the "a" command parser_a = subparsers.add_parser('a', help='a help', description='test me') parser_a.add_argument('bar', type=int, help='bar help') print(parser.parse_args()) ``` Here's the output of `python script.py a -h`: ``` usage: ex.py a [-h] bar test me positional arguments: bar bar help options: -h, --help show this help message and exit ``` Do you have the same setup? Or is there anything else that needs to be fixed? ---------- nosy: +sobolevn _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue45275> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com