[issue26196] Argparse breaks when a switch is given an argument beginning with a dash
SilentGhost
report at bugs.python.org
Mon Jan 25 06:48:59 EST 2016
SilentGhost added the comment:
If you're to drop the space between the argument and its value, e.g. try_args('-a-a'), it seems to work as intended. The third example (
try_args("-a", "--")) still wouldn't work, but it looks like a reasonable workaround to me.
----------
nosy: +SilentGhost, bethard
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue26196>
_______________________________________
More information about the Python-bugs-list
mailing list