[issue46142] python --help output is too long

Éric Araujo report at bugs.python.org
Sat Jan 1 13:47:28 EST 2022


Éric Araujo <merwok at netwok.org> added the comment:

Question about the implementation:
I’ve found the parsing of command-line params in Python/initconfig.c and Python/preconfig.c.
Help is handled in initconfig, X options in preconfig.

A) could add a value to the right struct for "-X help", set it in preconfig, handle it in initconfig (by printing X options help and exiting, maybe reusing the existing print help function or writing a very similar one next to it)
B) or detect the option in preconfig, print and exit right there

Which option is best?

----------
nosy: +vstinner

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue46142>
_______________________________________


More information about the Python-bugs-list mailing list