paul j3 added the comment: What are you trying to accomplish in the examples with a 'dest'? For a positional, 'dest' is derived from the 'foo' name. There is no need to supply 'dest', in fact produces the error you get. It has nothing to with this action type (as your last example demonstrates).
Your case with 'foo' and 'bar' shows that 'append_const' works fine. But be ware that such an action does not make much sense for a positional. Such an action takes no arguments, i.e. 'nargs=0'. So such a positional is always present, since it does not consume any `argv` strings. You might even get an error if you supply a string. (same would be true of 'store_true' and related actions). ---------- nosy: +paul.j3 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue24419> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com