[issue33109] argparse: make new 'required' argument to add_subparsers default to False instead of True

Anthony Sottile report at bugs.python.org
Tue May 15 16:46:39 EDT 2018


Anthony Sottile <asottile at umich.edu> added the comment:

According to the other bugs, the change in 3.3 was an inadvertent regression.  The fact that it didn't get fixed for so long is mostly due to the unmaintained state of argparse in the stdlib.  The change in behaviour here is the _fix_ of that regression.

Consistency with the rest of the framework to me feels pretty important.  subparsers are positional arguments and positional arguments by default are required.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue33109>
_______________________________________


More information about the Python-bugs-list mailing list