New submission from Nazime Koussaila Lakehal <nazime....@gmail.com>:

The parameter help in the method add_parser of _SubParsersAction (that we 
obtain with ArgumentParser.add_subparsers()) Is not documented.

In the documentation we can find:
The add_subparsers() method is normally called with no arguments and returns a 
special action object. This object has a single method, add_parser(), which 
takes a command name and any ArgumentParser constructor arguments, and returns 
an ArgumentParser object that can be modified as usual.

I found the parameter by accident and then I checked in the source code, it's 
unfortunate because the help parameter give really nice output when having sub 
commands.

the parameter 'aliases' is also not documented.

----------
assignee: docs@python
components: Documentation
messages: 363932
nosy: Nazime Koussaila Lakehal, docs@python
priority: normal
severity: normal
status: open
title: argparse: help parameter not documented in add_subparsers().add_parser
type: enhancement
versions: Python 2.7, Python 3.5, Python 3.6, Python 3.7, Python 3.8, Python 3.9

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue39935>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to