extras-map-one-to-one-to-modules

IN premise

Each optional dependency group maps 1:1 to a specific module: `pg` extra gates `reasons_lib/pg.py`, `cluster` extra gates `reasons_lib/cluster.py`, and `test-pg` is a superset combining `pg` and `test`.

Summary

Each optional dependency group in the package corresponds to exactly one module file, so installing the "pg" extra unlocks the Postgres module, "cluster" unlocks the clustering module, and "test-pg" bundles both Postgres and test dependencies together. This means you only pull in the code you can actually use, and the mapping is predictable — if you know which module you need, you know which extra to install.

Details

Sourceentries/2026/05/08/pyproject.md