[issue43160] argparse: add extend_const action

paul j3 report at bugs.python.org
Mon Feb 8 22:54:36 EST 2021


paul j3 <ajipanca at gmail.com> added the comment:

It's not clear what your patch does that the existing 'store_const' doesn't.   Even 'append_const' does the same except for a extra level of list/tuple nesting.

But I'll admit that I didn't much need for  'extend' addition, but others, including the original developer liked it.

I suspect users of your addition will get a surprise if they aren't careful to provide a list or tuple 'const':

    const='foobar'
    const=str

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue43160>
_______________________________________


More information about the Python-bugs-list mailing list