A roundup of notable Python ecosystem developments. PEP 842 proposes an `__export__` variable for explicit module public API whitelisting, complementing `__all__` but limited to runtime enforcement. PEP 837 proposes a `__json__` magic method for extensible JSON serialization, though the author questions why it's JSON-specific rather than a general serialization mechanism. On the tooling side, uv 0.12 ships with breaking changes including `uv init` defaulting to build system mode, dropped legacy archive formats, and a new `uv upgrade` for bulk dependency upgrades. Ruff 0.16 dramatically expands default rules from 59 to 413, catching issues like blind excepts, mutable default arguments, and forgotten breakpoints. Also noted: Python 3.15 RC1 is available with lazy imports and frozen dicts, Django 6.1 adds a `FETCH_PEERS` setting to prevent N+1 queries, and a new `protobuf-py` package offers a more Pythonic protobuf API.

7m read timeFrom bitecode.dev
Post cover image
Table of contents
SummaryPEP 842 – Module ExportsPEP 837 – Extensible JSON serializationYou missed Astral news? We got Astral newsThe usual moar

Questions this post answers

What breaking changes does uv 0.12 introduce?

uv 0.12 drops support for legacy source archive formats (.tar.bz2, .tar.xz) to match PEP 625, requires a valid pylock.toml with mandatory fields, stops converting local dependencies to project-relative paths in pyproject.toml, and blocks packages named 'Python', 'python.py', or 'Python.exe' from shadowing the interpreter. It also raises the soft open-file limit at startup on Linux and macOS, and adds `uv upgrade` for bulk dependency upgrades. Python teams shipping uv upgrades track breaking changes like these on daily.dev before they hit CI.

How many rules does ruff 0.16 enable by default compared to previous versions?

Ruff 0.16 activates 413 rules by default, up from 59 in previous versions — a roughly 700% increase. Newly enforced rules flag `exec()` usage, blind excepts, assignment to `os.environ`, `strip()` called with multiple characters, mutable default arguments, forgotten `breakpoint()` calls, and redundant boolean conditionals. Developers adopting ruff across codebases find the full rule changelog faster on daily.dev.

What does PEP 837 propose for Python JSON serialization?

PEP 837 proposes a `__json__` magic method that any type can implement to declare how it serializes to JSON. This would let stdlib types like `Decimal`, `datetime`, and `Enum` serialize transparently without requiring a `default=` function or a custom `JSONEncoder` subclass at every call site. Third-party libraries could also implement it for automatic ecosystem-wide compatibility. Python developers weighing serialization design decisions follow PEP discussions like this on daily.dev.

17.4K Impressions