This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author telmich
Recipients bethard, r.david.murray, telmich
Date 2012-10-24.14:30:24
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1351089025.08.0.374505827358.issue16308@psf.upfronthosting.co.za>
In-reply-to
Content
Proposal / resume from the previous tests:

- add a parameter to add_subparsers(): required
   If required=True, one of the subcommand names need to be present.
   If required=False (default), allow parse_args() to return successfully, if no subcommand is given.

- Change implementation in such a way that using parser.set_defaults() on the main parser does not affect the sub parsers: Sub parsers are not related to the main parser like parent parsers and thus should not be affected by changes in the main parser.

The second change would allow catching the case of no subcommands given and can be used to catch the empty arguments case.
History
Date User Action Args
2012-10-24 14:30:25telmichsetrecipients: + telmich, bethard, r.david.murray
2012-10-24 14:30:25telmichsetmessageid: <1351089025.08.0.374505827358.issue16308@psf.upfronthosting.co.za>
2012-10-24 14:30:25telmichlinkissue16308 messages
2012-10-24 14:30:24telmichcreate