[Python-ideas] Suggestion: Collection type argument for argparse where nargs != None

2017-03-04 Thread David Mayo
A friend of mine (@bcjbcjbcj on twitter) came up with an idea for an argparse improvement that I'd like to propose for inclusion. Currently, argparse with nargs= collects arguments into a list (or a list of lists in the case of action="append"). I would like to propose adding a "collection type" a

[Python-ideas] Collection type argument for argparse where nargs != None

2017-08-04 Thread David Mayo
A friend of mine (@bcjbcjbcj on twitter) came up with an idea for an argparse improvement that I'd like to propose for inclusion. Currently, argparse with nargs= collects arguments into a list (or a list of lists in the case of action="append"). I would like to propose adding a "collection type" a

Re: [Python-ideas] Collection type argument for argparse where nargs != None

2017-08-04 Thread David Mayo
> callable to use after constructing the list couldn't you just do e.g. > `args.stuff = frozenset(args.stuff)` instead and just be explicit about it? > > On Fri, Aug 4, 2017, 06:01 David Mayo, wrote: > >> A friend of mine (@bcjbcjbcj on twitter) came up with an idea for