Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #110634
| Path | csiph.com!fu-berlin.de!uni-berlin.de!not-for-mail |
|---|---|
| From | "Joseph L. Casale" <jcasale@activenetwerx.com> |
| Newsgroups | comp.lang.python |
| Subject | RE: argparse and subparsers |
| Date | Tue, 28 Jun 2016 02:22:19 +0000 |
| Lines | 22 |
| Message-ID | <mailman.55.1467080552.2358.python-list@python.org> (permalink) |
| References | <4ab10ce55d564780b158c19817009b62@activenetwerx.com> <mailman.11.1466967381.2358.python-list@python.org> <nkqbl0$tim$1@dont-email.me> <b7729720de9c4954a69063bd3933a603@activenetwerx.com> |
| Mime-Version | 1.0 |
| Content-Type | text/plain; charset="us-ascii" |
| Content-Transfer-Encoding | quoted-printable |
| X-Trace | news.uni-berlin.de Qv/9QElku2DFO7dVOqZejQrA5sGO4P04nRvmLSv+4MbQ== |
| Return-Path | <jcasale@activenetwerx.com> |
| X-Original-To | python-list@python.org |
| Delivered-To | python-list@mail.python.org |
| X-Spam-Status | OK 0.006 |
| X-Spam-Evidence | '*H*': 0.99; '*S*': 0.00; 'keyed': 0.09; 'bug': 0.10; 'argparse': 0.16; 'argument.': 0.16; 'debated': 0.16; 'dictionary,': 0.16; 'etc...': 0.16; 'fits': 0.16; 'received:172.18.0': 0.16; 'received:io': 0.16; 'received:psf.io': 0.16; 'subject:argparse': 0.16; 'duplicate': 0.18; 'to:name :python-list@python.org': 0.20; 'tracker': 0.20; 'arguments': 0.22; 'seems': 0.23; 'passing': 0.23; 'thanks,': 0.24; 'header:In- Reply-To:1': 0.24; "doesn't": 0.26; 'sense': 0.26; 'parameters': 0.27; 'values': 0.28; 'interface': 0.29; 'foo': 0.33; 'clear': 0.35; 'but': 0.36; 'project': 0.36; 'to:addr:python-list': 0.36; 'subject:: ': 0.37; 'charset:us-ascii': 0.37; 'itself': 0.38; 'sure': 0.39; 'to:addr:python.org': 0.40; 'easy': 0.60; 'eye': 0.61; 'perspective.': 0.84 |
| X-Authority-Analysis | v=2.2 cv=QZUkhYTv c=1 sm=1 tr=0 a=g3mLq75WYuDrh3Lt0JSDww==:117 a=g3mLq75WYuDrh3Lt0JSDww==:17 a=L9H7d07YOLsA:10 a=9cW_t1CCXrUA:10 a=s5jvgZ67dGcA:10 a=pD_ry4oyNxEA:10 a=kHgwhut6nYtv92KsJEUA:9 |
| X-Spam-Checker-Version | SpamAssassin 3.4.0 (2014-02-07) on mail.activenetwerx.com |
| X-Spam-Level | |
| X-Spam-Status | No, score=-2.3 required=5.0 tests=ALL_TRUSTED,RP_MATCHES_RCVD autolearn=ham autolearn_force=no version=3.4.0 |
| Thread-Topic | argparse and subparsers |
| Thread-Index | AdHP2gSoxuCFxHcPRWiE5r3lwpEgMgAVxXoWACyPgkA= |
| In-Reply-To | <nkqbl0$tim$1@dont-email.me> |
| Accept-Language | en-CA, en-US |
| Content-Language | en-US |
| X-MS-Has-Attach | |
| X-MS-TNEF-Correlator | |
| x-originating-ip | [172.18.0.200] |
| X-CMAE-Envelope | MS4wfJS68wxW+BZemZxN6TzigX+NYkFeqFxBdE2dJMeLFXZlR3CPupYko2tbSOiqdcMsiT5m8LQFMZ7dHuj8lBHjPr8g6eCltebobt+lfjl65k9W3S/h0Tbf yRf5wvkv5yaOgulGHKGkLH8ggRDY2LBXvJIKgYftkfv/unKYhV3UZicAAxwqYg3q0J771b3hkjvYPw== |
| X-BeenThere | python-list@python.org |
| X-Mailman-Version | 2.1.22 |
| Precedence | list |
| List-Id | General discussion list for the Python programming language <python-list.python.org> |
| List-Unsubscribe | <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe> |
| List-Archive | <http://mail.python.org/pipermail/python-list/> |
| List-Post | <mailto:python-list@python.org> |
| List-Help | <mailto:python-list-request@python.org?subject=help> |
| List-Subscribe | <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe> |
| X-Mailman-Original-Message-ID | <b7729720de9c4954a69063bd3933a603@activenetwerx.com> |
| X-Mailman-Original-References | <4ab10ce55d564780b158c19817009b62@activenetwerx.com> <mailman.11.1466967381.2358.python-list@python.org> <nkqbl0$tim$1@dont-email.me> |
| Xref | csiph.com comp.lang.python:110634 |
Show key headers only | View raw
> Not sure if this fits the bill, or makes sense here, but I came cross > "docopt" which touts itself as a "Command-line interface description > language". I used it in a project and it seems to be pretty easy to use > as well as elegant. It stores the arguments & values as a dictionary, > keyed by the argument. Yea I have had my eye on docopt for a while, it doesn't support multiple subparsers, as I am passing duplicate parameters from its perspective. Imagine: foo.py --host 172.18.0.4 --port 766 foo --warning 42 --critical 77 bar --warning 4.2 --critical 7.7 etc... The shortcoming to argparse has been debated to death and the bug tracker was just left hanging. To be honest, I am not clear on the opposition to it... Thanks, jlc
Back to comp.lang.python | Previous | Next — Previous in thread | Find similar | Unroll thread
argparse and subparsers "Joseph L. Casale" <jcasale@activenetwerx.com> - 2016-06-26 18:51 +0000
Re: argparse and subparsers Lawrence D’Oliveiro <lawrencedo99@gmail.com> - 2016-06-26 20:15 -0700
Re: argparse and subparsers Sachin Garg <s.garg.computer@gmail.com> - 2016-06-27 00:55 -0400
Re: argparse and subparsers Lawrence D’Oliveiro <lawrencedo99@gmail.com> - 2016-06-26 22:34 -0700
Re: argparse and subparsers Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2016-06-27 20:28 +1000
Re: argparse and subparsers Sachin Garg <s.garg.computer@gmail.com> - 2016-06-27 13:22 -0400
Re: argparse and subparsers Michele Simionato <michele.simionato@gmail.com> - 2016-06-28 03:02 -0700
RE: argparse and subparsers "Joseph L. Casale" <jcasale@activenetwerx.com> - 2016-06-28 02:22 +0000
csiph-web