RSS Amplifier

Blog

Newest Python PEPs

Newest Python Enhancement Proposals (PEPs): Information on new language features and some meta-information like release procedure and schedules.

peps.python.orgSource feed ↗10 posts

Live Last read · last published · next check

Written by

Latest posts

PEP 844: ``public`` and ``private`` builtins

This PEP proposes adding two new builtin functions, public() and private(), which document the public interface of a module by keeping its __all__ synchronized with the names actually defined to be public in that module. Both are used as decorators (@public and @private) on class and function definitions, so that a name’s visibility is declared exactly once, at the point where the name is defined.…

PEP 842: Module Exports

This PEP proposes an export statement that modules can use to express intent about the visibility of variables from outside the module.

PEP 841: Adding Frozen Syntax to Optimize Immutable Types

This PEP proposes frozen display syntax: f{1, 2, 3} evaluates to a frozenset, and f{'a': 1} evaluates to a frozendict. Because immutability is guaranteed by the syntax itself rather than inferred from usage, the compiler can treat frozen displays as first-class citizens of its optimization pipeline: constant displays are folded into a single LOAD_CONST with an exact result type at compile time and…

PEP 840: Name Resolution in Class Namespaces

There is a long-standing inconsistency in the way variable names are resolved in classes. Several alternatives to resolve this inconsistency are discussed.

PEP 839: PyFrozenSetWriter and PyFrozenDictWriter C API

Add two builder (“writer”) C APIs, PyFrozenSetWriter and PyFrozenDictWriter, following the design of PyBytesWriter (PEP 782). A writer collects items internally; *_Finish() produces the immutable object — a frozenset or a frozendict (PEP 814) — in a single pass, without ever exposing a mutable intermediate object.

PEP 838: Adding python-version to pyvenv.cfg

This PEP proposes adding a python-version field to pyvenv.cfg which records the Python interpreter used by a virtual environment. It records only the major and minor version to be resilient to patch version updates.

PEP 837: Extensible JSON serialization

This PEP adds an extension mechanism to the json encoder consisting of three complementary parts, one per level of customization:

PEP 836: JIT Go Brrr: The Path to a Supported JIT Compiler for CPython

The experimental Just-in-Time (JIT) compiler has been part of CPython’s main branch since Python 3.13. PEP 744 described part of its initial design and explicitly deferred a number of questions about the JIT’s long-term status. Since then, the JIT has been re-architected and matured considerably. In Python 3.15, it delivers a measurable, reproducible speedup over the interpreter (about 4-12%…

PEP 835: Shorthand syntax for Annotated type metadata

This PEP proposes overloading the @ operator on types to allow writing Annotated[T, M] as T @M.

PEP 833: Freezing the HTML simple repository API

This PEP proposes freezing the standard HTML representation of the simple repository API, as originally specified in PEP 503 and updated over subsequent PEPs.