30. Python Runtime Services¶
The modules described in this chapter provide a wide range of services related to the Python interpreter and its interaction with its environment. Here’s an overview:
- 30.1.
sys— System-specific parameters and functions - 30.2.
sysconfig— Provide access to Python’s configuration information - 30.3.
builtins— Built-in objects - 30.4.
__main__— Top-level script environment - 30.5.
warnings— Warning control - 30.6.
dataclasses— Data Classes - 30.7.
contextlib— Utilities forwith-statement contexts - 30.8.
abc— Abstract Base Classes - 30.9.
atexit— Exit handlers - 30.10.
traceback— Print or retrieve a stack traceback - 30.11.
__future__— Future statement definitions - 30.12.
gc— Garbage Collector interface - 30.13.
inspect— Inspect live objects- 30.13.1. Types and members
- 30.13.2. Retrieving source code
- 30.13.3. Introspecting callables with the Signature object
- 30.13.4. Classes and functions
- 30.13.5. The interpreter stack
- 30.13.6. Fetching attributes statically
- 30.13.7. Current State of Generators and Coroutines
- 30.13.8. Code Objects Bit Flags
- 30.13.9. Command Line Interface
- 30.14.
site— Site-specific configuration hook
