paul j3 added the comment: This patch fixes both help and error formatting.
A module level '_format_metavars' does the formatting for both. I have tried several alternatives, including using the 'usage' style. There is similarity between this fix and that for issue 16468 (custom choices), though I don't think they conflict. In both cases, code needed to format the usage or help is also needed to help format error messages. Issue 9849 (better nargs warning) is another case where error checking in the parser depends on the formatter. In the long run we may want to refactor these issues. ---------- Added file: http://bugs.python.org/file35049/issue14074_1.patch _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue14074> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com