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 mapleoin
Recipients bethard, mapleoin
Date 2012-07-07.08:45:40
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1341650741.0.0.256570615986.issue15271@psf.upfronthosting.co.za>
In-reply-to
Content
To reproduce:

>>> import argparse
[74536 refs]
>>> parser = argparse.ArgumentParser()
[74809 refs]
>>> parser.add_argument("foo")
>>> parser.add_argument("foo")
>>> parser.parse_args(["bar"])

usage: ipython [-h] foo foo
ipython: error: too few arguments
An exception has occurred, use %tb to see the full traceback.

SystemExit: 2

>>> parser.parse_args(["bar", "baz"])
>>> Namespace(foo='baz')

So it actually makes you provide two arguments, but it loses/ignores the first one and there's no way to get it back.
History
Date User Action Args
2012-07-07 08:45:41mapleoinsetrecipients: + mapleoin, bethard
2012-07-07 08:45:41mapleoinsetmessageid: <1341650741.0.0.256570615986.issue15271@psf.upfronthosting.co.za>
2012-07-07 08:45:40mapleoinlinkissue15271 messages
2012-07-07 08:45:40mapleoincreate