diff --git a/planning/releases/2.9.0.md b/planning/releases/2.9.0.md new file mode 100644 index 0000000..1292078 --- /dev/null +++ b/planning/releases/2.9.0.md @@ -0,0 +1,37 @@ +# modern-di-fastapi 2.9.0 — modern-di 2.25 integration seams + +Maintenance release. **No public API change** — `setup_di`, `FromDI`, +`build_di_container`, and the context providers keep their signatures and +behavior. It adopts modern-di 2.25's blessed integration seams and raises the +floor. + +## Internal refactors + +- **`container.add_providers(...)` replaces the `providers_registry` reach-in.** + `build_di_container` registered `_CONNECTION_PROVIDERS` by poking + `container.providers_registry.add_providers(...)` directly; it now calls the + public `container.add_providers(...)` seam. +- **`container.resolve_dependency(...)` replaces the copy-pasted marker + dispatch.** `Dependency.__call__` used to branch on + `isinstance(self.dependency, providers.AbstractProvider)` to choose between + `resolve_provider` and `resolve` itself; that dispatch now lives in modern-di's + own `resolve_dependency`, so `FromDI` no longer duplicates logic modern-di + maintains. + +## Packaging + +- **`modern-di` floor raised to `>=2.25,<3`** (was `>=2.21.0,<3`). The seams + above (`Container.add_providers`, `Container.resolve_dependency`) were added + in modern-di 2.25.0 (modern-python/modern-di#283). + +## Downstream + +Requires **`modern-di>=2.25`**. There is no API or behavior change, so +application code that uses `setup_di` / `FromDI` needs no edits — only the +`modern-di` floor moves. + +## Internals + +- 100% line coverage maintained; `ruff`, `ty`, and `eof-fixer` clean. +- `architecture/container-lifecycle.md` and `architecture/dependency-resolution.md` + updated to describe the new seams.