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.

Author elypter
Recipients elypter
Date 2018-01-15.00:35:35
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1515976536.21.0.467229070634.issue32552@psf.upfronthosting.co.za>
In-reply-to
Content
If you use formatter_class=argparse.ArgumentDefaultsHelpFormatter in the constructor then the defaults that you include in arguments get automatically added to the help text. this looks great for int and Strings but not for files.

example:
  -suffixes [SUFFIXES]
                        suffixes file which contains keywords that are often
                        the last part of a class or style name of a sticky bar
                        (default: <open file 'sources/suffixes.txt', mode 'r'
                        at 0xb71385f8>)

it should rather look like

  -suffixes [SUFFIXES]
                        suffixes file which contains keywords that are often
                        the last part of a class or style name of a sticky bar
                        (default:'sources/suffixes.txt')


the same holds probably true for more exotic datatypes. so an alternative or an addition could be to add an option to arguments to not add the default to the help text
History
Date User Action Args
2018-01-15 00:35:36elyptersetrecipients: + elypter
2018-01-15 00:35:36elyptersetmessageid: <1515976536.21.0.467229070634.issue32552@psf.upfronthosting.co.za>
2018-01-15 00:35:36elypterlinkissue32552 messages
2018-01-15 00:35:35elyptercreate