@@ -492,16 +492,18 @@ Miscellaneous options
492
492
Reserved for various implementation-specific options. CPython currently
493
493
defines the following possible values:
494
494
495
- * ``-X faulthandler `` to enable :mod: `faulthandler `;
495
+ * ``-X faulthandler `` to enable :mod: `faulthandler `.
496
+ See also :envvar: `PYTHONFAULTHANDLER `.
496
497
* ``-X showrefcount `` to output the total reference count and number of used
497
498
memory blocks when the program finishes or after each statement in the
498
499
interactive interpreter. This only works on :ref: `debug builds
499
500
<debug-build>`.
500
501
* ``-X tracemalloc `` to start tracing Python memory allocations using the
501
502
:mod: `tracemalloc ` module. By default, only the most recent frame is
502
503
stored in a traceback of a trace. Use ``-X tracemalloc=NFRAME `` to start
503
- tracing with a traceback limit of *NFRAME * frames. See the
504
- :func: `tracemalloc.start ` for more information.
504
+ tracing with a traceback limit of *NFRAME * frames.
505
+ See :func: `tracemalloc.start ` and :envvar: `PYTHONTRACEMALLOC `
506
+ for more information.
505
507
* ``-X int_max_str_digits `` configures the :ref: `integer string conversion
506
508
length limitation <int_max_str_digits>`. See also
507
509
:envvar: `PYTHONINTMAXSTRDIGITS `.
@@ -516,6 +518,7 @@ Miscellaneous options
516
518
* ``-X utf8 `` enables the :ref: `Python UTF-8 Mode <utf8-mode >`.
517
519
``-X utf8=0 `` explicitly disables :ref: `Python UTF-8 Mode <utf8-mode >`
518
520
(even when it would otherwise activate automatically).
521
+ See also :envvar: `PYTHONUTF8 `.
519
522
* ``-X pycache_prefix=PATH `` enables writing ``.pyc `` files to a parallel
520
523
tree rooted at the given directory instead of to the code tree. See also
521
524
:envvar: `PYTHONPYCACHEPREFIX `.
@@ -847,16 +850,18 @@ conflict.
847
850
Python memory allocations using the :mod: `tracemalloc ` module. The value of
848
851
the variable is the maximum number of frames stored in a traceback of a
849
852
trace. For example, ``PYTHONTRACEMALLOC=1 `` stores only the most recent
850
- frame. See the :func: `tracemalloc.start ` for more information.
853
+ frame.
854
+ See the :func: `tracemalloc.start ` function for more information.
855
+ This is equivalent to setting the :option: `-X ` ``tracemalloc `` option.
851
856
852
857
.. versionadded :: 3.4
853
858
854
859
855
860
.. envvar :: PYTHONPROFILEIMPORTTIME
856
861
857
862
If this environment variable is set to a non-empty string, Python will
858
- show how long each import takes. This is exactly equivalent to setting
859
- `` -X importtime `` on the command line .
863
+ show how long each import takes.
864
+ This is equivalent to setting the :option: ` -X ` `` importtime `` option .
860
865
861
866
.. versionadded :: 3.7
862
867
@@ -998,6 +1003,7 @@ conflict.
998
1003
If this environment variable is set to a non-empty string, enable
999
1004
:ref: `Python Development Mode <devmode >`, introducing additional runtime
1000
1005
checks that are too expensive to be enabled by default.
1006
+ This is equivalent to setting the :option: `-X ` ``dev `` option.
1001
1007
1002
1008
.. versionadded :: 3.7
1003
1009
0 commit comments