PEP 829: Structured Startup Configuration via .site.toml Files

This PEP proposes a TOML-based configuration file format to replace the .pth file mechanism used by site.py during interpreter startup. The new format, using files named .site.toml, provides structured configuration for extending sys.path and executing package initialization code, replacing the current ad-hoc .pth format that conflates path configuration with arbitrary code execution.

#python

PEP 829 – Structured Startup Configuration via .site.toml Files | peps.python.org

This PEP proposes a TOML-based configuration file format to replace the .pth file mechanism used by site.py during interpreter startup. The new format, using files named <package>.site.toml, provides structured configuration for extending sys.path and ...

Python Enhancement Proposals (PEPs)