[issue34299] argparse description formatting
Zsolt Cserna
report at bugs.python.org
Tue Jul 31 15:43:52 EDT 2018
Zsolt Cserna <cserna.zsolt at gmail.com> added the comment:
You would need to use the RawTextHelpFormatter as format_class for the constructor. In this case, argparse will apply no re-wrapping of the description.
import argparse
parser = argparse.ArgumentParser(description="""foo
bar
baz""", formatter_class=argparse.RawTextHelpFormatter)
----------
nosy: +csernazs
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue34299>
_______________________________________
More information about the Python-bugs-list
mailing list