Message 385733 - Python tracker

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.

Content
Paul said:
I haven't had a chance to study your longer posts, but it seems to me that the AddFruitAction example could just as well be implemented with 

    parser.add_argument('--color', nargs='*', action='append')

with post parsing processing to create the 'fruits' dicts from the appended lists.  


That was also my first reaction, Paul, when I read Tadek's proposal. But I quickly realized that particularly with the feature of "capture and reset to default" that the number of instances of a particular optional and the number of positionals do not always match, and there is no way to correlate them later, even if they are all captured and saved.