Python Development Mode — Python 3.16.0a0 documentation

docs.python.org

Tin mới

pydoc — Documentation generator and online help system

doctest — Test interactive Python examples

Python Module Index

3.16.0a0 Documentation

The Python Standard Library

Effects of the Python Development Mode¶

The Python Development Mode introduces additional runtime checks that are too expensive to be enabled by default. It should not be more verbose than the default if the code is correct; new warnings are only emitted when

Python debug build

The Python Development Mode introduces additional runtime checks that are too expensive to be enabled by default. It should not be more verbose than the default if the code is correct; new warnings are only emitted when

DeprecationWarning

PyMem_SetupDebugHooks()

Install debug hooks on memory allocators to check for:

faulthandler.enable()

Call faulthandler.enable() at Python startup to install handlers for the SIGSEGV, SIGFPE, SIGABRT, SIGBUS and SIGILL signals to dump the Python traceback on a crash.

asyncio debug mode

Enable asyncio debug mode. For example, asyncio checks for coroutines that were not awaited and logs them.

asyncio: Asynchronous I/O.

Enable asyncio debug mode. For example, asyncio checks for coroutines that were not awaited and logs them.

sys.flags.dev_mode

tracemalloc: Trace memory allocations.

Enabling the Python Development Mode is similar to the following command, but with additional effects described below:

Effects of the Python Development Mode¶

Enabling the Python Development Mode is similar to the following command, but with additional effects described below:

Effects of the Python Development Mode¶

Enabling the Python Development Mode is similar to the following command, but with additional effects described below: