Message377469
Consider the following example from the Python documentation:
>>> parser = argparse.ArgumentParser(prog='PROG')
>>> parser.add_argument('--foo')
>>> parser.add_argument('command')
>>> parser.add_argument('args', nargs=argparse.REMAINDER)
Now show the help:
>>> parser.parse_args(['-h'])
This prints:
usage: PROG [-h] [--foo FOO] command ...
positional arguments:
command
args
Note that "args" is not shown in the synopsis. I suggest that the synopsis should instead say:
usage: PROG [-h] [--foo FOO] command args... |
|
| Date |
User |
Action |
Args |
| 2020-09-24 23:40:02 | rrt | set | recipients:
+ rrt |
| 2020-09-24 23:40:02 | rrt | set | messageid: <1600990802.2.0.259982030629.issue41856@roundup.psfhosted.org> |
| 2020-09-24 23:40:02 | rrt | link | issue41856 messages |
| 2020-09-24 23:40:01 | rrt | create | |
|