@@ -495,16 +495,18 @@ Miscellaneous options
495
495
Reserved for various implementation-specific options. CPython currently
496
496
defines the following possible values:
497
497
498
- * ``-X faulthandler `` to enable :mod: `faulthandler `;
498
+ * ``-X faulthandler `` to enable :mod: `faulthandler `.
499
+ See also :envvar: `PYTHONFAULTHANDLER `.
499
500
* ``-X showrefcount `` to output the total reference count and number of used
500
501
memory blocks when the program finishes or after each statement in the
501
502
interactive interpreter. This only works on :ref: `debug builds
502
503
<debug-build>`.
503
504
* ``-X tracemalloc `` to start tracing Python memory allocations using the
504
505
:mod: `tracemalloc ` module. By default, only the most recent frame is
505
506
stored in a traceback of a trace. Use ``-X tracemalloc=NFRAME `` to start
506
- tracing with a traceback limit of *NFRAME * frames. See the
507
- :func: `tracemalloc.start ` for more information.
507
+ tracing with a traceback limit of *NFRAME * frames.
508
+ See :func: `tracemalloc.start ` and :envvar: `PYTHONTRACEMALLOC `
509
+ for more information.
508
510
* ``-X int_max_str_digits `` configures the :ref: `integer string conversion
509
511
length limitation <int_max_str_digits>`. See also
510
512
:envvar: `PYTHONINTMAXSTRDIGITS `.
@@ -519,6 +521,7 @@ Miscellaneous options
519
521
* ``-X utf8 `` enables the :ref: `Python UTF-8 Mode <utf8-mode >`.
520
522
``-X utf8=0 `` explicitly disables :ref: `Python UTF-8 Mode <utf8-mode >`
521
523
(even when it would otherwise activate automatically).
524
+ See also :envvar: `PYTHONUTF8 `.
522
525
* ``-X pycache_prefix=PATH `` enables writing ``.pyc `` files to a parallel
523
526
tree rooted at the given directory instead of to the code tree. See also
524
527
:envvar: `PYTHONPYCACHEPREFIX `.
@@ -861,16 +864,18 @@ conflict.
861
864
Python memory allocations using the :mod: `tracemalloc ` module. The value of
862
865
the variable is the maximum number of frames stored in a traceback of a
863
866
trace. For example, ``PYTHONTRACEMALLOC=1 `` stores only the most recent
864
- frame. See the :func: `tracemalloc.start ` for more information.
867
+ frame.
868
+ See the :func: `tracemalloc.start ` function for more information.
869
+ This is equivalent to setting the :option: `-X ` ``tracemalloc `` option.
865
870
866
871
.. versionadded :: 3.4
867
872
868
873
869
874
.. envvar :: PYTHONPROFILEIMPORTTIME
870
875
871
876
If this environment variable is set to a non-empty string, Python will
872
- show how long each import takes. This is exactly equivalent to setting
873
- `` -X importtime `` on the command line .
877
+ show how long each import takes.
878
+ This is equivalent to setting the :option: ` -X ` `` importtime `` option .
874
879
875
880
.. versionadded :: 3.7
876
881
@@ -1012,6 +1017,7 @@ conflict.
1012
1017
If this environment variable is set to a non-empty string, enable
1013
1018
:ref: `Python Development Mode <devmode >`, introducing additional runtime
1014
1019
checks that are too expensive to be enabled by default.
1020
+ This is equivalent to setting the :option: `-X ` ``dev `` option.
1015
1021
1016
1022
.. versionadded :: 3.7
1017
1023
0 commit comments