[issue40509] In argparse, allow REMAINDER(...) arguments in a mutually exclusive group

paul j3 report at bugs.python.org
Sat Oct 17 21:48:44 EDT 2020


paul j3 <ajipanca at gmail.com> added the comment:

A more recent issue shows that the use of a '*' positional in a multually_exclusive_group is poorly understood and documented.  

https://bugs.python.org/issue41854

That's part of why I am not enthusiastic about extending this to include REMAINDER.  

And on rereading Shani's posts, I realize I don't understand what this has to do with subcommands.  Is this the 'add_subparsers' mechanism, or just the idea of using a trailing part of sys.argv as input to another parser or script?

I think discussion of this topic can only proceed with some concrete examples, and may be even a proposed code change (not necessarily a formal patch or pull request).

----------

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


More information about the Python-bugs-list mailing list