[issue24754] argparse add_argument with action="store_true", type=bool should not crash
Douglas Bagnall
report at bugs.python.org
Tue Aug 4 01:06:50 CEST 2015
Douglas Bagnall added the comment:
Thanks paul.j3 and r.david.murray,
I see your points.
What led me to this was automatically generating command line options from a Gstreamer element, mapping
the Gstreamer property types to Python types. Then I special-cased the action="store_true" for the boolean ones and was surprised by the somewhat unclear error message.
As you suggest, paul.j3, "type" is in some ways an unfortunate choice of keyword for this, but it too late to change that.
----------
resolution: -> not a bug
status: open -> closed
_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue24754>
_______________________________________
More information about the Python-bugs-list
mailing list