{
    "content": [
        {
            "type": "text",
            "text": "# PYTHON (man)\n\n**Summary:** python - an interpreted, interactive, object-oriented programming language\n\n**Synopsis:** python [ -B ] [ -b ] [ -d ] [ -E ] [ -h ] [ -i ] [ -I ]\n[ -m module-name ] [ -q ] [ -O ] [ -OO ] [ -s ] [ -S ] [ -u ]\n[ -v ] [ -V ] [ -W argument ] [ -x ] [ -X option ] [ -?  ]\n[ --check-hash-based-pycs default | always | never ]\n[ -c command | script | - ] [ arguments ]\n\n## Section Outline\n\n- **NAME** (2 lines)\n- **SYNOPSIS** (6 lines)\n- **DESCRIPTION** (14 lines)\n- **COMMAND LINE OPTIONS** (1 lines) — 20 subsections\n  - -B (1 lines)\n  - -b (2 lines)\n  - -c (6 lines)\n  - -d (1 lines)\n  - -E (2 lines)\n  - -h ,  -? ,  --help (2 lines)\n  - -i -c (4 lines)\n  - -I -E -s (4 lines)\n  - -m (4 lines)\n  - -O (2 lines)\n  - -OO -O (2 lines)\n  - -q (2 lines)\n  - -s (1 lines)\n  - -S (3 lines)\n  - -u (2 lines)\n  - -v (4 lines)\n  - -V ,  --version (4 lines)\n  - -W (47 lines)\n  - -X (45 lines)\n  - -x (2 lines)\n- **INTERPRETER INTERFACE** (23 lines)\n- **FILES AND DIRECTORIES** (16 lines)\n- **ENVIRONMENT VARIABLES** (133 lines) — 1 subsections\n  - Debug-mode variables (11 lines)\n- **AUTHOR** (2 lines)\n- **INTERNET RESOURCES** (7 lines)\n- **LICENSING** (7 lines)\n\n## Full Content\n\n### NAME\n\npython - an interpreted, interactive, object-oriented programming language\n\n### SYNOPSIS\n\npython [ -B ] [ -b ] [ -d ] [ -E ] [ -h ] [ -i ] [ -I ]\n[ -m module-name ] [ -q ] [ -O ] [ -OO ] [ -s ] [ -S ] [ -u ]\n[ -v ] [ -V ] [ -W argument ] [ -x ] [ -X option ] [ -?  ]\n[ --check-hash-based-pycs default | always | never ]\n[ -c command | script | - ] [ arguments ]\n\n### DESCRIPTION\n\nPython is an interpreted, interactive, object-oriented programming language that combines re‐\nmarkable power with very clear syntax.  For an introduction to programming in Python, see the\nPython  Tutorial.   The  Python Library Reference documents built-in and standard types, con‐\nstants, functions and modules.  Finally, the Python Reference Manual describes the syntax and\nsemantics of the core language in (perhaps too) much detail.  (These documents may be located\nvia the INTERNET RESOURCES below; they may be installed on your system as well.)\n\nPython's basic power can be extended with your own modules written in C or C++.  On most sys‐\ntems  such  modules may be dynamically loaded.  Python is also adaptable as an extension lan‐\nguage for existing applications.  See the internal documentation for hints.\n\nDocumentation for installed Python modules and packages can be viewed by  running  the  pydoc\nprogram.\n\n### COMMAND LINE OPTIONS\n\n#### -B\n\n#### -b\n\nbytes/bytearray with str. (-bb: issue errors)\n\n#### -c\n\nSpecify the command to execute (see next section).  This terminates  the  option  list\n(following options are passed as arguments to the command).\n\n--check-hash-based-pycs mode\nConfigure how Python evaluates the up-to-dateness of hash-based .pyc files.\n\n#### -d\n\n#### -E\n\nof the interpreter.\n\n#### -h ,  -? ,  --help\n\nPrints the usage for the interpreter executable and exits.\n\n#### -i -c\n\nmode  after  executing the script or the command.  It does not read the $PYTHONSTARTUP\nfile.  This can be useful to inspect global variables or a stack trace when  a  script\nraises an exception.\n\n#### -I -E -s\n\ncontains neither the script's directory nor the user's  site-packages  directory.  All\nPYTHON*  environment  variables are ignored, too.  Further restrictions may be imposed\nto prevent the user from injecting malicious code.\n\n#### -m\n\nSearches sys.path for the named module and  runs  the  corresponding  .py  file  as  a\nscript.  This terminates the option list (following options are passed as arguments to\nthe module).\n\n#### -O\n\nthe filename for compiled (bytecode) files by adding .opt-1 before the .pyc extension.\n\n#### -OO -O\n\nby adding .opt-2 before the .pyc extension.\n\n#### -q\n\nnon-interactive mode.\n\n#### -s\n\n#### -S\n\nthat it entails.  Also disable these manipulations  if  site  is  explicitly  imported\nlater.\n\n#### -u\n\nthe stdin stream.\n\n#### -v\n\nbuilt-in  module) from which it is loaded.  When given twice, print a message for each\nfile that is checked for when searching for a module.  Also  provides  information  on\nmodule cleanup at exit.\n\n#### -V ,  --version\n\nPrints the Python version number of the executable and exits.  When given twice, print\nmore information about the build.\n\n#### -W\n\nWarning control. Python's warning machinery by  default  prints  warning  messages  to\nsys.stderr.\n\nThe  simplest settings apply a particular action unconditionally to all warnings emit‐\nted by a process (even those that are otherwise ignored by default):\n\n-Wdefault  # Warn once per call location\n-Werror    # Convert to exceptions\n-Walways   # Warn every time\n-Wmodule   # Warn once per calling module\n-Wonce     # Warn once per Python process\n-Wignore   # Never warn\n\nThe action names can be abbreviated as desired and the interpreter will  resolve  them\nto the appropriate action name. For example, -Wi is the same as -Wignore .\n\nThe full form of argument is: action:message:category:module:lineno\n\nEmpty  fields  match  all values; trailing empty fields may be omitted. For example -W\nignore::DeprecationWarning ignores all DeprecationWarning warnings.\n\nThe action field is as explained above but only applies to warnings that match the re‐\nmaining fields.\n\nThe message field must match the whole printed warning message; this match is case-in‐\nsensitive.\n\nThe category field matches the warning category (ex: \"DeprecationWarning\"). This  must\nbe  a class name; the match test whether the actual warning category of the message is\na subclass of the specified warning category.\n\nThe module field matches the (fully-qualified) module name; this match is  case-sensi‐\ntive.\n\nThe  lineno  field matches the line number, where zero matches all line numbers and is\nthus equivalent to an omitted line number.\n\nMultiple -W options can be given; when a warning matches more than one option, the ac‐\ntion  for  the  last  matching  option  is  performed.  Invalid -W options are ignored\n(though, a warning message is printed about invalid options when the first warning  is\nissued).\n\nWarnings can also be controlled using the PYTHONWARNINGS environment variable and from\nwithin a Python program using the warnings module.  For example, the  warnings.filter‐\nwarnings() function can be used to use a regular expression on the warning message.\n\n#### -X\n\nSet implementation specific option. The following options are available:\n\n-X faulthandler: enable faulthandler\n\n-X showrefcount: output the total reference count and number of used\nmemory blocks when the program finishes or after each statement in the\ninteractive interpreter. This only works on debug builds\n\n-X tracemalloc: start tracing Python memory allocations using the\ntracemalloc module. By default, only the most recent frame is stored in a\ntraceback of a trace. Use -X tracemalloc=NFRAME to start tracing with a\ntraceback limit of NFRAME frames\n\n-X importtime: show how long each import takes. It shows module name,\ncumulative time (including nested imports) and self time (excluding\nnested imports). Note that its output may be broken in multi-threaded\napplication. Typical usage is python3 -X importtime -c 'import asyncio'\n\n-X dev: enable CPython's \"development mode\", introducing additional runtime\nchecks which are too expensive to be enabled by default. It will not be\nmore verbose than the default if the code is correct: new warnings are\nonly emitted when an issue is detected. Effect of the developer mode:\n* Add default warning filter, as -W default\n* Install debug hooks on memory allocators: see the PyMemSetupDebugHooks()\nC function\n* Enable the faulthandler module to dump the Python traceback on a crash\n* Enable asyncio debug mode\n* Set the devmode attribute of sys.flags to True\n* io.IOBase destructor logs close() exceptions\n\n-X utf8: enable UTF-8 mode for operating system interfaces, overriding the default\nlocale-aware  mode.  -X  utf8=0  explicitly  disables UTF-8 mode (even when it\nwould\notherwise activate automatically). See PYTHONUTF8 for more details\n\n-X pycacheprefix=PATH: enable writing .pyc files to a parallel tree rooted at the\ngiven directory instead of to the code tree.\n\n-X warndefaultencoding: enable opt-in EncodingWarning for 'encoding=None'\n\n-X intmaxstrdigits=number: limit the size of int<->str conversions.\nThis helps avoid denial of service attacks when parsing untrusted data.\nThe default is sys.intinfo.defaultmaxstrdigits.  0 disables.\n\n#### -x\n\nWarning: the line numbers in error messages will be off by one!\n\n### INTERPRETER INTERFACE\n\nThe  interpreter  interface resembles that of the UNIX shell: when called with standard input\nconnected to a tty device, it prompts for commands and executes them until an  EOF  is  read;\nwhen called with a file name argument or with a file as standard input, it reads and executes\na script from that file; when called with -c command, it  executes  the  Python  statement(s)\ngiven as command.  Here command may contain multiple statements separated by newlines.  Lead‐\ning whitespace is significant in Python statements!  In non-interactive mode, the entire  in‐\nput is parsed before it is executed.\n\nIf available, the script name and additional arguments thereafter are passed to the script in\nthe Python variable sys.argv, which is a list of strings (you must first  import  sys  to  be\nable  to  access  it).   If no script name is given, sys.argv[0] is an empty string; if -c is\nused, sys.argv[0] contains the string '-c'.  Note that options interpreted by the Python  in‐\nterpreter itself are not placed in sys.argv.\n\nIn  interactive  mode,  the  primary prompt is `>>>'; the second prompt (which appears when a\ncommand is not complete) is `...'.  The prompts can be changed by assignment  to  sys.ps1  or\nsys.ps2.   The  interpreter quits when it reads an EOF at a prompt.  When an unhandled excep‐\ntion occurs, a stack trace is printed and control returns to the primary prompt;  in  non-in‐\nteractive  mode,  the interpreter exits after printing the stack trace.  The interrupt signal\nraises the KeyboardInterrupt exception; other UNIX signals are not caught (except  that  SIG‐\nPIPE is sometimes ignored, in favor of the IOError exception).  Error messages are written to\nstderr.\n\n### FILES AND DIRECTORIES\n\nThese are subject to difference depending on local installation  conventions;  ${prefix}  and\n${execprefix} are installation-dependent and should be interpreted as for GNU software; they\nmay be the same.  On Debian GNU/{Hurd,Linux} the default for both is /usr.\n\n${execprefix}/bin/python\nRecommended location of the interpreter.\n\n${prefix}/lib/python<version>\n${execprefix}/lib/python<version>\nRecommended locations of the directories containing the standard modules.\n\n${prefix}/include/python<version>\n${execprefix}/include/python<version>\nRecommended locations of the directories containing the include files needed  for  de‐\nveloping Python extensions and embedding the interpreter.\n\n### ENVIRONMENT VARIABLES\n\nPYTHONHOME\nChange  the  location of the standard Python libraries.  By default, the libraries are\nsearched  in  ${prefix}/lib/python<version>  and   ${execprefix}/lib/python<version>,\nwhere  ${prefix}  and  ${execprefix} are installation-dependent directories, both de‐\nfaulting to /usr/local.  When $PYTHONHOME is set to a single directory, its value  re‐\nplaces  both ${prefix} and ${execprefix}.  To specify different values for these, set\n$PYTHONHOME to ${prefix}:${execprefix}.\n\nPYTHONPATH\nAugments the default search path for module files.  The format  is  the  same  as  the\nshell's  $PATH: one or more directory pathnames separated by colons.  Non-existent di‐\nrectories are silently ignored.  The default search path  is  installation  dependent,\nbut  generally  begins with ${prefix}/lib/python<version> (see PYTHONHOME above).  The\ndefault search path is always appended to $PYTHONPATH.  If a script argument is given,\nthe  directory  containing the script is inserted in the path in front of $PYTHONPATH.\nThe search path can be manipulated from  within  a  Python  program  as  the  variable\nsys.path.\n\nPYTHONPLATLIBDIR\nOverride sys.platlibdir.\n\nPYTHONSTARTUP\nIf  this is the name of a readable file, the Python commands in that file are executed\nbefore the first prompt is displayed in interactive mode.  The file is executed in the\nsame name space where interactive commands are executed so that objects defined or im‐\nported in it can be used without qualification in the interactive  session.   You  can\nalso change the prompts sys.ps1 and sys.ps2 in this file.\n\nPYTHONOPTIMIZE\nIf  this is set to a non-empty string it is equivalent to specifying the -O option. If\nset to an integer, it is equivalent to specifying -O multiple times.\n\nPYTHONDEBUG\nIf this is set to a non-empty string it is equivalent to specifying the -d option.  If\nset to an integer, it is equivalent to specifying -d multiple times.\n\nPYTHONDONTWRITEBYTECODE\nIf  this  is  set  to  a non-empty string it is equivalent to specifying the -B option\n(don't try to write .pyc files).\n\nPYTHONINSPECT\nIf this is set to a non-empty string it is equivalent to specifying the -i option.\n\nPYTHONIOENCODING\nIf this is set before running the interpreter, it  overrides  the  encoding  used  for\nstdin/stdout/stderr,  in the syntax encodingname:errorhandler The errorhandler part is\noptional and has the same meaning as in str.encode. For stderr, the errorhandler\npart is ignored; the handler will always be ´backslashreplace´.\n\nPYTHONNOUSERSITE\nIf this is set to a non-empty string it is equivalent  to  specifying  the  -s  option\n(Don't add the user site directory to sys.path).\n\nPYTHONUNBUFFERED\nIf this is set to a non-empty string it is equivalent to specifying the -u option.\n\nPYTHONVERBOSE\nIf  this is set to a non-empty string it is equivalent to specifying the -v option. If\nset to an integer, it is equivalent to specifying -v multiple times.\n\nPYTHONWARNINGS\nIf this is set to a comma-separated string it is equivalent to specifying the  -W  op‐\ntion for each separate value.\n\nPYTHONHASHSEED\nIf  this variable is set to \"random\", a random value is used to seed the hashes of str\nand bytes objects.\n\nIf PYTHONHASHSEED is set to an integer value, it is used as a fixed seed for  generat‐\ning  the hash() of the types covered by the hash randomization.  Its purpose is to al‐\nlow repeatable hashing, such as for selftests for the interpreter itself, or to  allow\na cluster of python processes to share hash values.\n\nThe  integer  must  be  a  decimal number in the range [0,4294967295].  Specifying the\nvalue 0 will disable hash randomization.\n\nPYTHONINTMAXSTRDIGITS\nLimit the maximum digit characters in an int value when converting from a  string  and\nwhen  converting  an int back to a str.  A value of 0 disables the limit.  Conversions\nto or from bases 2, 4, 8, 16, and 32 are never limited.\n\nPYTHONMALLOC\nSet the Python memory allocators and/or install debug hooks. The available memory  al‐\nlocators  are malloc and pymalloc.  The available debug hooks are debug, mallocdebug,\nand pymallocdebug.\n\nWhen Python is compiled in debug mode, the default is  pymallocdebug  and  the  debug\nhooks are automatically used. Otherwise, the default is pymalloc.\n\nPYTHONMALLOCSTATS\nIf  set to a non-empty string, Python will print statistics of the pymalloc memory al‐\nlocator every time a new pymalloc object arena is created, and on shutdown.\n\nThis variable is ignored if the $PYTHONMALLOC environment variable is  used  to  force\nthe  malloc(3) allocator of the C library, or if Python is configured without pymalloc\nsupport.\n\nPYTHONASYNCIODEBUG\nIf this environment variable is set to a non-empty string, enable the  debug  mode  of\nthe asyncio module.\n\nPYTHONTRACEMALLOC\nIf this environment variable is set to a non-empty string, start tracing Python memory\nallocations using the tracemalloc module.\n\nThe value of the variable is the maximum number of frames stored in a traceback  of  a\ntrace. For example, PYTHONTRACEMALLOC=1 stores only the most recent frame.\n\nPYTHONFAULTHANDLER\nIf  this  environment  variable is set to a non-empty string, faulthandler.enable() is\ncalled at startup: install a handler for SIGSEGV, SIGFPE, SIGABRT, SIGBUS  and  SIGILL\nsignals to dump the Python traceback.\n\nThis is equivalent to the -X faulthandler option.\n\nPYTHONEXECUTABLE\nIf  this  environment variable is set, sys.argv[0] will be set to its value instead of\nthe value got through the C runtime. Only works on Mac OS X.\n\nPYTHONUSERBASE\nDefines the user base directory, which is used to compute the path of the  user  site-\npackages  directory  and  Distutils  installation  paths  for  python setup.py install\n--user.\n\nPYTHONPROFILEIMPORTTIME\nIf this environment variable is set to a non-empty string, Python will show  how  long\neach  import takes. This is exactly equivalent to setting -X importtime on the command\nline.\n\nPYTHONBREAKPOINT\nIf this environment variable is set to 0, it disables the default debugger. It can  be\nset to the callable of your debugger of choice.\n\n#### Debug-mode variables\n\nSetting these variables only has an effect in a debug build of Python, that is, if Python was\nconfigured with the --with-pydebug build option.\n\nPYTHONTHREADDEBUG\nIf this environment variable is set, Python will print threading debug info.  The fea‐\nture is deprecated in Python 3.10 and will be removed in Python 3.12.\n\nPYTHONDUMPREFS\nIf  this  environment  variable  is set, Python will dump objects and reference counts\nstill alive after shutting down the interpreter.\n\n### AUTHOR\n\nThe Python Software Foundation: https://www.python.org/psf/\n\n### INTERNET RESOURCES\n\nMain website:  https://www.python.org/\nDocumentation:  https://docs.python.org/\nDeveloper resources:  https://devguide.python.org/\nDownloads:  https://www.python.org/downloads/\nModule repository:  https://pypi.org/\nNewsgroups:  comp.lang.python, comp.lang.python.announce\n\n### LICENSING\n\nPython is distributed under an Open Source license.  See the file  \"LICENSE\"  in  the  Python\nsource  distribution  for information on terms & conditions for accessing and otherwise using\nPython and for a DISCLAIMER OF ALL WARRANTIES.\n\n\n\nPYTHON(1)\n\n"
        }
    ],
    "structuredContent": {
        "command": "PYTHON",
        "section": "",
        "mode": "man",
        "summary": "python - an interpreted, interactive, object-oriented programming language",
        "synopsis": "python [ -B ] [ -b ] [ -d ] [ -E ] [ -h ] [ -i ] [ -I ]\n[ -m module-name ] [ -q ] [ -O ] [ -OO ] [ -s ] [ -S ] [ -u ]\n[ -v ] [ -V ] [ -W argument ] [ -x ] [ -X option ] [ -?  ]\n[ --check-hash-based-pycs default | always | never ]\n[ -c command | script | - ] [ arguments ]",
        "tldr_summary": null,
        "tldr_examples": [],
        "tldr_source": null,
        "flags": [
            {
                "flag": "-B",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-b",
                "long": null,
                "arg": null,
                "description": "bytes/bytearray with str. (-bb: issue errors)"
            },
            {
                "flag": "-c",
                "long": null,
                "arg": null,
                "description": "Specify the command to execute (see next section). This terminates the option list (following options are passed as arguments to the command). --check-hash-based-pycs mode Configure how Python evaluates the up-to-dateness of hash-based .pyc files."
            },
            {
                "flag": "-d",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-E",
                "long": null,
                "arg": null,
                "description": "of the interpreter."
            },
            {
                "flag": "-?",
                "long": "--help",
                "arg": null,
                "description": "Prints the usage for the interpreter executable and exits."
            },
            {
                "flag": "-c",
                "long": null,
                "arg": null,
                "description": "mode after executing the script or the command. It does not read the $PYTHONSTARTUP file. This can be useful to inspect global variables or a stack trace when a script raises an exception."
            },
            {
                "flag": "-s",
                "long": null,
                "arg": null,
                "description": "contains neither the script's directory nor the user's site-packages directory. All PYTHON* environment variables are ignored, too. Further restrictions may be imposed to prevent the user from injecting malicious code."
            },
            {
                "flag": "-m",
                "long": null,
                "arg": null,
                "description": "Searches sys.path for the named module and runs the corresponding .py file as a script. This terminates the option list (following options are passed as arguments to the module)."
            },
            {
                "flag": "-O",
                "long": null,
                "arg": null,
                "description": "the filename for compiled (bytecode) files by adding .opt-1 before the .pyc extension."
            },
            {
                "flag": "-O",
                "long": null,
                "arg": null,
                "description": "by adding .opt-2 before the .pyc extension."
            },
            {
                "flag": "-q",
                "long": null,
                "arg": null,
                "description": "non-interactive mode."
            },
            {
                "flag": "-s",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-S",
                "long": null,
                "arg": null,
                "description": "that it entails. Also disable these manipulations if site is explicitly imported later."
            },
            {
                "flag": "-u",
                "long": null,
                "arg": null,
                "description": "the stdin stream."
            },
            {
                "flag": "-v",
                "long": null,
                "arg": null,
                "description": "built-in module) from which it is loaded. When given twice, print a message for each file that is checked for when searching for a module. Also provides information on module cleanup at exit."
            },
            {
                "flag": "-V",
                "long": "--version",
                "arg": null,
                "description": "Prints the Python version number of the executable and exits. When given twice, print more information about the build."
            },
            {
                "flag": "-W",
                "long": null,
                "arg": null,
                "description": "Warning control. Python's warning machinery by default prints warning messages to sys.stderr. The simplest settings apply a particular action unconditionally to all warnings emit‐ ted by a process (even those that are otherwise ignored by default): -Wdefault # Warn once per call location -Werror # Convert to exceptions -Walways # Warn every time -Wmodule # Warn once per calling module -Wonce # Warn once per Python process -Wignore # Never warn The action names can be abbreviated as desired and the interpreter will resolve them to the appropriate action name. For example, -Wi is the same as -Wignore . The full form of argument is: action:message:category:module:lineno Empty fields match all values; trailing empty fields may be omitted. For example -W ignore::DeprecationWarning ignores all DeprecationWarning warnings. The action field is as explained above but only applies to warnings that match the re‐ maining fields. The message field must match the whole printed warning message; this match is case-in‐ sensitive. The category field matches the warning category (ex: \"DeprecationWarning\"). This must be a class name; the match test whether the actual warning category of the message is a subclass of the specified warning category. The module field matches the (fully-qualified) module name; this match is case-sensi‐ tive. The lineno field matches the line number, where zero matches all line numbers and is thus equivalent to an omitted line number. Multiple -W options can be given; when a warning matches more than one option, the ac‐ tion for the last matching option is performed. Invalid -W options are ignored (though, a warning message is printed about invalid options when the first warning is issued). Warnings can also be controlled using the PYTHONWARNINGS environment variable and from within a Python program using the warnings module. For example, the warnings.filter‐ warnings() function can be used to use a regular expression on the warning message."
            },
            {
                "flag": "-X",
                "long": null,
                "arg": null,
                "description": "Set implementation specific option. The following options are available: -X faulthandler: enable faulthandler -X showrefcount: output the total reference count and number of used memory blocks when the program finishes or after each statement in the interactive interpreter. This only works on debug builds -X tracemalloc: start tracing Python memory allocations using the tracemalloc module. By default, only the most recent frame is stored in a traceback of a trace. Use -X tracemalloc=NFRAME to start tracing with a traceback limit of NFRAME frames -X importtime: show how long each import takes. It shows module name, cumulative time (including nested imports) and self time (excluding nested imports). Note that its output may be broken in multi-threaded application. Typical usage is python3 -X importtime -c 'import asyncio' -X dev: enable CPython's \"development mode\", introducing additional runtime checks which are too expensive to be enabled by default. It will not be more verbose than the default if the code is correct: new warnings are only emitted when an issue is detected. Effect of the developer mode: * Add default warning filter, as -W default * Install debug hooks on memory allocators: see the PyMemSetupDebugHooks() C function * Enable the faulthandler module to dump the Python traceback on a crash * Enable asyncio debug mode * Set the devmode attribute of sys.flags to True * io.IOBase destructor logs close() exceptions -X utf8: enable UTF-8 mode for operating system interfaces, overriding the default locale-aware mode. -X utf8=0 explicitly disables UTF-8 mode (even when it would otherwise activate automatically). See PYTHONUTF8 for more details -X pycacheprefix=PATH: enable writing .pyc files to a parallel tree rooted at the given directory instead of to the code tree. -X warndefaultencoding: enable opt-in EncodingWarning for 'encoding=None' -X intmaxstrdigits=number: limit the size of int<->str conversions. This helps avoid denial of service attacks when parsing untrusted data. The default is sys.intinfo.defaultmaxstrdigits. 0 disables."
            },
            {
                "flag": "-x",
                "long": null,
                "arg": null,
                "description": "Warning: the line numbers in error messages will be off by one!"
            }
        ],
        "examples": [],
        "see_also": [],
        "section_outline": [
            {
                "name": "NAME",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "SYNOPSIS",
                "lines": 6,
                "subsections": []
            },
            {
                "name": "DESCRIPTION",
                "lines": 14,
                "subsections": []
            },
            {
                "name": "COMMAND LINE OPTIONS",
                "lines": 1,
                "subsections": [
                    {
                        "name": "-B",
                        "lines": 1,
                        "flag": "-B"
                    },
                    {
                        "name": "-b",
                        "lines": 2,
                        "flag": "-b"
                    },
                    {
                        "name": "-c",
                        "lines": 6,
                        "flag": "-c"
                    },
                    {
                        "name": "-d",
                        "lines": 1,
                        "flag": "-d"
                    },
                    {
                        "name": "-E",
                        "lines": 2,
                        "flag": "-E"
                    },
                    {
                        "name": "-h ,  -? ,  --help",
                        "lines": 2,
                        "flag": "-?",
                        "long": "--help"
                    },
                    {
                        "name": "-i -c",
                        "lines": 4,
                        "flag": "-c"
                    },
                    {
                        "name": "-I -E -s",
                        "lines": 4,
                        "flag": "-s"
                    },
                    {
                        "name": "-m",
                        "lines": 4,
                        "flag": "-m"
                    },
                    {
                        "name": "-O",
                        "lines": 2,
                        "flag": "-O"
                    },
                    {
                        "name": "-OO -O",
                        "lines": 2,
                        "flag": "-O"
                    },
                    {
                        "name": "-q",
                        "lines": 2,
                        "flag": "-q"
                    },
                    {
                        "name": "-s",
                        "lines": 1,
                        "flag": "-s"
                    },
                    {
                        "name": "-S",
                        "lines": 3,
                        "flag": "-S"
                    },
                    {
                        "name": "-u",
                        "lines": 2,
                        "flag": "-u"
                    },
                    {
                        "name": "-v",
                        "lines": 4,
                        "flag": "-v"
                    },
                    {
                        "name": "-V ,  --version",
                        "lines": 4,
                        "flag": "-V",
                        "long": "--version"
                    },
                    {
                        "name": "-W",
                        "lines": 47,
                        "flag": "-W"
                    },
                    {
                        "name": "-X",
                        "lines": 45,
                        "flag": "-X"
                    },
                    {
                        "name": "-x",
                        "lines": 2,
                        "flag": "-x"
                    }
                ]
            },
            {
                "name": "INTERPRETER INTERFACE",
                "lines": 23,
                "subsections": []
            },
            {
                "name": "FILES AND DIRECTORIES",
                "lines": 16,
                "subsections": []
            },
            {
                "name": "ENVIRONMENT VARIABLES",
                "lines": 133,
                "subsections": [
                    {
                        "name": "Debug-mode variables",
                        "lines": 11
                    }
                ]
            },
            {
                "name": "AUTHOR",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "INTERNET RESOURCES",
                "lines": 7,
                "subsections": []
            },
            {
                "name": "LICENSING",
                "lines": 7,
                "subsections": []
            }
        ],
        "sections": {
            "NAME": {
                "content": "python - an interpreted, interactive, object-oriented programming language\n",
                "subsections": []
            },
            "SYNOPSIS": {
                "content": "python [ -B ] [ -b ] [ -d ] [ -E ] [ -h ] [ -i ] [ -I ]\n[ -m module-name ] [ -q ] [ -O ] [ -OO ] [ -s ] [ -S ] [ -u ]\n[ -v ] [ -V ] [ -W argument ] [ -x ] [ -X option ] [ -?  ]\n[ --check-hash-based-pycs default | always | never ]\n[ -c command | script | - ] [ arguments ]\n",
                "subsections": []
            },
            "DESCRIPTION": {
                "content": "Python is an interpreted, interactive, object-oriented programming language that combines re‐\nmarkable power with very clear syntax.  For an introduction to programming in Python, see the\nPython  Tutorial.   The  Python Library Reference documents built-in and standard types, con‐\nstants, functions and modules.  Finally, the Python Reference Manual describes the syntax and\nsemantics of the core language in (perhaps too) much detail.  (These documents may be located\nvia the INTERNET RESOURCES below; they may be installed on your system as well.)\n\nPython's basic power can be extended with your own modules written in C or C++.  On most sys‐\ntems  such  modules may be dynamically loaded.  Python is also adaptable as an extension lan‐\nguage for existing applications.  See the internal documentation for hints.\n\nDocumentation for installed Python modules and packages can be viewed by  running  the  pydoc\nprogram.\n",
                "subsections": []
            },
            "COMMAND LINE OPTIONS": {
                "content": "",
                "subsections": [
                    {
                        "name": "-B",
                        "content": "",
                        "flag": "-B"
                    },
                    {
                        "name": "-b",
                        "content": "bytes/bytearray with str. (-bb: issue errors)\n",
                        "flag": "-b"
                    },
                    {
                        "name": "-c",
                        "content": "Specify the command to execute (see next section).  This terminates  the  option  list\n(following options are passed as arguments to the command).\n\n--check-hash-based-pycs mode\nConfigure how Python evaluates the up-to-dateness of hash-based .pyc files.\n",
                        "flag": "-c"
                    },
                    {
                        "name": "-d",
                        "content": "",
                        "flag": "-d"
                    },
                    {
                        "name": "-E",
                        "content": "of the interpreter.\n",
                        "flag": "-E"
                    },
                    {
                        "name": "-h ,  -? ,  --help",
                        "content": "Prints the usage for the interpreter executable and exits.\n",
                        "flag": "-?",
                        "long": "--help"
                    },
                    {
                        "name": "-i -c",
                        "content": "mode  after  executing the script or the command.  It does not read the $PYTHONSTARTUP\nfile.  This can be useful to inspect global variables or a stack trace when  a  script\nraises an exception.\n",
                        "flag": "-c"
                    },
                    {
                        "name": "-I -E -s",
                        "content": "contains neither the script's directory nor the user's  site-packages  directory.  All\nPYTHON*  environment  variables are ignored, too.  Further restrictions may be imposed\nto prevent the user from injecting malicious code.\n",
                        "flag": "-s"
                    },
                    {
                        "name": "-m",
                        "content": "Searches sys.path for the named module and  runs  the  corresponding  .py  file  as  a\nscript.  This terminates the option list (following options are passed as arguments to\nthe module).\n",
                        "flag": "-m"
                    },
                    {
                        "name": "-O",
                        "content": "the filename for compiled (bytecode) files by adding .opt-1 before the .pyc extension.\n",
                        "flag": "-O"
                    },
                    {
                        "name": "-OO -O",
                        "content": "by adding .opt-2 before the .pyc extension.\n",
                        "flag": "-O"
                    },
                    {
                        "name": "-q",
                        "content": "non-interactive mode.\n",
                        "flag": "-q"
                    },
                    {
                        "name": "-s",
                        "content": "",
                        "flag": "-s"
                    },
                    {
                        "name": "-S",
                        "content": "that it entails.  Also disable these manipulations  if  site  is  explicitly  imported\nlater.\n",
                        "flag": "-S"
                    },
                    {
                        "name": "-u",
                        "content": "the stdin stream.\n",
                        "flag": "-u"
                    },
                    {
                        "name": "-v",
                        "content": "built-in  module) from which it is loaded.  When given twice, print a message for each\nfile that is checked for when searching for a module.  Also  provides  information  on\nmodule cleanup at exit.\n",
                        "flag": "-v"
                    },
                    {
                        "name": "-V ,  --version",
                        "content": "Prints the Python version number of the executable and exits.  When given twice, print\nmore information about the build.\n\n",
                        "flag": "-V",
                        "long": "--version"
                    },
                    {
                        "name": "-W",
                        "content": "Warning control. Python's warning machinery by  default  prints  warning  messages  to\nsys.stderr.\n\nThe  simplest settings apply a particular action unconditionally to all warnings emit‐\nted by a process (even those that are otherwise ignored by default):\n\n-Wdefault  # Warn once per call location\n-Werror    # Convert to exceptions\n-Walways   # Warn every time\n-Wmodule   # Warn once per calling module\n-Wonce     # Warn once per Python process\n-Wignore   # Never warn\n\nThe action names can be abbreviated as desired and the interpreter will  resolve  them\nto the appropriate action name. For example, -Wi is the same as -Wignore .\n\nThe full form of argument is: action:message:category:module:lineno\n\nEmpty  fields  match  all values; trailing empty fields may be omitted. For example -W\nignore::DeprecationWarning ignores all DeprecationWarning warnings.\n\nThe action field is as explained above but only applies to warnings that match the re‐\nmaining fields.\n\nThe message field must match the whole printed warning message; this match is case-in‐\nsensitive.\n\nThe category field matches the warning category (ex: \"DeprecationWarning\"). This  must\nbe  a class name; the match test whether the actual warning category of the message is\na subclass of the specified warning category.\n\nThe module field matches the (fully-qualified) module name; this match is  case-sensi‐\ntive.\n\nThe  lineno  field matches the line number, where zero matches all line numbers and is\nthus equivalent to an omitted line number.\n\nMultiple -W options can be given; when a warning matches more than one option, the ac‐\ntion  for  the  last  matching  option  is  performed.  Invalid -W options are ignored\n(though, a warning message is printed about invalid options when the first warning  is\nissued).\n\nWarnings can also be controlled using the PYTHONWARNINGS environment variable and from\nwithin a Python program using the warnings module.  For example, the  warnings.filter‐\nwarnings() function can be used to use a regular expression on the warning message.\n\n",
                        "flag": "-W"
                    },
                    {
                        "name": "-X",
                        "content": "Set implementation specific option. The following options are available:\n\n-X faulthandler: enable faulthandler\n\n-X showrefcount: output the total reference count and number of used\nmemory blocks when the program finishes or after each statement in the\ninteractive interpreter. This only works on debug builds\n\n-X tracemalloc: start tracing Python memory allocations using the\ntracemalloc module. By default, only the most recent frame is stored in a\ntraceback of a trace. Use -X tracemalloc=NFRAME to start tracing with a\ntraceback limit of NFRAME frames\n\n-X importtime: show how long each import takes. It shows module name,\ncumulative time (including nested imports) and self time (excluding\nnested imports). Note that its output may be broken in multi-threaded\napplication. Typical usage is python3 -X importtime -c 'import asyncio'\n\n-X dev: enable CPython's \"development mode\", introducing additional runtime\nchecks which are too expensive to be enabled by default. It will not be\nmore verbose than the default if the code is correct: new warnings are\nonly emitted when an issue is detected. Effect of the developer mode:\n* Add default warning filter, as -W default\n* Install debug hooks on memory allocators: see the PyMemSetupDebugHooks()\nC function\n* Enable the faulthandler module to dump the Python traceback on a crash\n* Enable asyncio debug mode\n* Set the devmode attribute of sys.flags to True\n* io.IOBase destructor logs close() exceptions\n\n-X utf8: enable UTF-8 mode for operating system interfaces, overriding the default\nlocale-aware  mode.  -X  utf8=0  explicitly  disables UTF-8 mode (even when it\nwould\notherwise activate automatically). See PYTHONUTF8 for more details\n\n-X pycacheprefix=PATH: enable writing .pyc files to a parallel tree rooted at the\ngiven directory instead of to the code tree.\n\n-X warndefaultencoding: enable opt-in EncodingWarning for 'encoding=None'\n\n-X intmaxstrdigits=number: limit the size of int<->str conversions.\nThis helps avoid denial of service attacks when parsing untrusted data.\nThe default is sys.intinfo.defaultmaxstrdigits.  0 disables.\n\n",
                        "flag": "-X"
                    },
                    {
                        "name": "-x",
                        "content": "Warning: the line numbers in error messages will be off by one!\n",
                        "flag": "-x"
                    }
                ]
            },
            "INTERPRETER INTERFACE": {
                "content": "The  interpreter  interface resembles that of the UNIX shell: when called with standard input\nconnected to a tty device, it prompts for commands and executes them until an  EOF  is  read;\nwhen called with a file name argument or with a file as standard input, it reads and executes\na script from that file; when called with -c command, it  executes  the  Python  statement(s)\ngiven as command.  Here command may contain multiple statements separated by newlines.  Lead‐\ning whitespace is significant in Python statements!  In non-interactive mode, the entire  in‐\nput is parsed before it is executed.\n\nIf available, the script name and additional arguments thereafter are passed to the script in\nthe Python variable sys.argv, which is a list of strings (you must first  import  sys  to  be\nable  to  access  it).   If no script name is given, sys.argv[0] is an empty string; if -c is\nused, sys.argv[0] contains the string '-c'.  Note that options interpreted by the Python  in‐\nterpreter itself are not placed in sys.argv.\n\nIn  interactive  mode,  the  primary prompt is `>>>'; the second prompt (which appears when a\ncommand is not complete) is `...'.  The prompts can be changed by assignment  to  sys.ps1  or\nsys.ps2.   The  interpreter quits when it reads an EOF at a prompt.  When an unhandled excep‐\ntion occurs, a stack trace is printed and control returns to the primary prompt;  in  non-in‐\nteractive  mode,  the interpreter exits after printing the stack trace.  The interrupt signal\nraises the KeyboardInterrupt exception; other UNIX signals are not caught (except  that  SIG‐\nPIPE is sometimes ignored, in favor of the IOError exception).  Error messages are written to\nstderr.\n",
                "subsections": []
            },
            "FILES AND DIRECTORIES": {
                "content": "These are subject to difference depending on local installation  conventions;  ${prefix}  and\n${execprefix} are installation-dependent and should be interpreted as for GNU software; they\nmay be the same.  On Debian GNU/{Hurd,Linux} the default for both is /usr.\n\n${execprefix}/bin/python\nRecommended location of the interpreter.\n\n${prefix}/lib/python<version>\n${execprefix}/lib/python<version>\nRecommended locations of the directories containing the standard modules.\n\n${prefix}/include/python<version>\n${execprefix}/include/python<version>\nRecommended locations of the directories containing the include files needed  for  de‐\nveloping Python extensions and embedding the interpreter.\n",
                "subsections": []
            },
            "ENVIRONMENT VARIABLES": {
                "content": "PYTHONHOME\nChange  the  location of the standard Python libraries.  By default, the libraries are\nsearched  in  ${prefix}/lib/python<version>  and   ${execprefix}/lib/python<version>,\nwhere  ${prefix}  and  ${execprefix} are installation-dependent directories, both de‐\nfaulting to /usr/local.  When $PYTHONHOME is set to a single directory, its value  re‐\nplaces  both ${prefix} and ${execprefix}.  To specify different values for these, set\n$PYTHONHOME to ${prefix}:${execprefix}.\n\nPYTHONPATH\nAugments the default search path for module files.  The format  is  the  same  as  the\nshell's  $PATH: one or more directory pathnames separated by colons.  Non-existent di‐\nrectories are silently ignored.  The default search path  is  installation  dependent,\nbut  generally  begins with ${prefix}/lib/python<version> (see PYTHONHOME above).  The\ndefault search path is always appended to $PYTHONPATH.  If a script argument is given,\nthe  directory  containing the script is inserted in the path in front of $PYTHONPATH.\nThe search path can be manipulated from  within  a  Python  program  as  the  variable\nsys.path.\n\nPYTHONPLATLIBDIR\nOverride sys.platlibdir.\n\nPYTHONSTARTUP\nIf  this is the name of a readable file, the Python commands in that file are executed\nbefore the first prompt is displayed in interactive mode.  The file is executed in the\nsame name space where interactive commands are executed so that objects defined or im‐\nported in it can be used without qualification in the interactive  session.   You  can\nalso change the prompts sys.ps1 and sys.ps2 in this file.\n\nPYTHONOPTIMIZE\nIf  this is set to a non-empty string it is equivalent to specifying the -O option. If\nset to an integer, it is equivalent to specifying -O multiple times.\n\nPYTHONDEBUG\nIf this is set to a non-empty string it is equivalent to specifying the -d option.  If\nset to an integer, it is equivalent to specifying -d multiple times.\n\nPYTHONDONTWRITEBYTECODE\nIf  this  is  set  to  a non-empty string it is equivalent to specifying the -B option\n(don't try to write .pyc files).\n\nPYTHONINSPECT\nIf this is set to a non-empty string it is equivalent to specifying the -i option.\n\nPYTHONIOENCODING\nIf this is set before running the interpreter, it  overrides  the  encoding  used  for\nstdin/stdout/stderr,  in the syntax encodingname:errorhandler The errorhandler part is\noptional and has the same meaning as in str.encode. For stderr, the errorhandler\npart is ignored; the handler will always be ´backslashreplace´.\n\nPYTHONNOUSERSITE\nIf this is set to a non-empty string it is equivalent  to  specifying  the  -s  option\n(Don't add the user site directory to sys.path).\n\nPYTHONUNBUFFERED\nIf this is set to a non-empty string it is equivalent to specifying the -u option.\n\nPYTHONVERBOSE\nIf  this is set to a non-empty string it is equivalent to specifying the -v option. If\nset to an integer, it is equivalent to specifying -v multiple times.\n\nPYTHONWARNINGS\nIf this is set to a comma-separated string it is equivalent to specifying the  -W  op‐\ntion for each separate value.\n\nPYTHONHASHSEED\nIf  this variable is set to \"random\", a random value is used to seed the hashes of str\nand bytes objects.\n\nIf PYTHONHASHSEED is set to an integer value, it is used as a fixed seed for  generat‐\ning  the hash() of the types covered by the hash randomization.  Its purpose is to al‐\nlow repeatable hashing, such as for selftests for the interpreter itself, or to  allow\na cluster of python processes to share hash values.\n\nThe  integer  must  be  a  decimal number in the range [0,4294967295].  Specifying the\nvalue 0 will disable hash randomization.\n\nPYTHONINTMAXSTRDIGITS\nLimit the maximum digit characters in an int value when converting from a  string  and\nwhen  converting  an int back to a str.  A value of 0 disables the limit.  Conversions\nto or from bases 2, 4, 8, 16, and 32 are never limited.\n\nPYTHONMALLOC\nSet the Python memory allocators and/or install debug hooks. The available memory  al‐\nlocators  are malloc and pymalloc.  The available debug hooks are debug, mallocdebug,\nand pymallocdebug.\n\nWhen Python is compiled in debug mode, the default is  pymallocdebug  and  the  debug\nhooks are automatically used. Otherwise, the default is pymalloc.\n\nPYTHONMALLOCSTATS\nIf  set to a non-empty string, Python will print statistics of the pymalloc memory al‐\nlocator every time a new pymalloc object arena is created, and on shutdown.\n\nThis variable is ignored if the $PYTHONMALLOC environment variable is  used  to  force\nthe  malloc(3) allocator of the C library, or if Python is configured without pymalloc\nsupport.\n\nPYTHONASYNCIODEBUG\nIf this environment variable is set to a non-empty string, enable the  debug  mode  of\nthe asyncio module.\n\nPYTHONTRACEMALLOC\nIf this environment variable is set to a non-empty string, start tracing Python memory\nallocations using the tracemalloc module.\n\nThe value of the variable is the maximum number of frames stored in a traceback  of  a\ntrace. For example, PYTHONTRACEMALLOC=1 stores only the most recent frame.\n\nPYTHONFAULTHANDLER\nIf  this  environment  variable is set to a non-empty string, faulthandler.enable() is\ncalled at startup: install a handler for SIGSEGV, SIGFPE, SIGABRT, SIGBUS  and  SIGILL\nsignals to dump the Python traceback.\n\nThis is equivalent to the -X faulthandler option.\n\nPYTHONEXECUTABLE\nIf  this  environment variable is set, sys.argv[0] will be set to its value instead of\nthe value got through the C runtime. Only works on Mac OS X.\n\nPYTHONUSERBASE\nDefines the user base directory, which is used to compute the path of the  user  site-\npackages  directory  and  Distutils  installation  paths  for  python setup.py install\n--user.\n\nPYTHONPROFILEIMPORTTIME\nIf this environment variable is set to a non-empty string, Python will show  how  long\neach  import takes. This is exactly equivalent to setting -X importtime on the command\nline.\n\nPYTHONBREAKPOINT\nIf this environment variable is set to 0, it disables the default debugger. It can  be\nset to the callable of your debugger of choice.\n",
                "subsections": [
                    {
                        "name": "Debug-mode variables",
                        "content": "Setting these variables only has an effect in a debug build of Python, that is, if Python was\nconfigured with the --with-pydebug build option.\n\nPYTHONTHREADDEBUG\nIf this environment variable is set, Python will print threading debug info.  The fea‐\nture is deprecated in Python 3.10 and will be removed in Python 3.12.\n\nPYTHONDUMPREFS\nIf  this  environment  variable  is set, Python will dump objects and reference counts\nstill alive after shutting down the interpreter.\n"
                    }
                ]
            },
            "AUTHOR": {
                "content": "The Python Software Foundation: https://www.python.org/psf/\n",
                "subsections": []
            },
            "INTERNET RESOURCES": {
                "content": "Main website:  https://www.python.org/\nDocumentation:  https://docs.python.org/\nDeveloper resources:  https://devguide.python.org/\nDownloads:  https://www.python.org/downloads/\nModule repository:  https://pypi.org/\nNewsgroups:  comp.lang.python, comp.lang.python.announce\n",
                "subsections": []
            },
            "LICENSING": {
                "content": "Python is distributed under an Open Source license.  See the file  \"LICENSE\"  in  the  Python\nsource  distribution  for information on terms & conditions for accessing and otherwise using\nPython and for a DISCLAIMER OF ALL WARRANTIES.\n\n\n\nPYTHON(1)",
                "subsections": []
            }
        }
    }
}