I have code that looks like:
list_of_choices = ["foo", "bar", "baz"]
parser = argparse.ArgumentParser(description='some description')
parser.add_argument("-n","--name","-o","--othername",dest=name,
choices=list_of_choices
and what I get for output looks like:
-n {foo,bar,baz}, --name {foo,bar,baz}, -o {foo,bar,baz},
--othername {foo,bar,baz}
What I would like is:
-n, --name, -o, --othername {foo,bar,baz}
For context, there are historical reasons why we need two names for the same option and the actual list of choices is 22 elements long, so it looks much worse than the above.
This problem is subtly different than Python argparse: Lots of choices results in ugly help output in that I am not working with two separate options and it is okay to have it all on the line as above.