[issue31415] Add -X option to show import time

Antoine Pitrou report at bugs.python.org
Sat Nov 4 09:17:31 EDT 2017


Antoine Pitrou <pitrou at free.fr> added the comment:

One benefit (or drawback, depending on how you see it) of the -X option is that it wouldn't propagate to child processes spawned by multiprocessing.  See _args_from_interpreter_flags() in Lib/subprocess.py.

More generally, the idea that we should remove a command line option because there's an environment variable sounds dubious to me.  Should we do the same for all command-line options?  The faulthandler module can be enabled either using the `PYTHONFAULTHANDLER` environment variable or by specifying `-X faulthandler` on the command line.

The only serious reason I can imagine would be that the -X option has a significant maintenance cost.

----------
nosy: +pitrou

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


More information about the Python-bugs-list mailing list