Skip to content

docs: correct how modern_di_fixture resolves in the README API section - #37

Merged
lesnik512 merged 1 commit into
mainfrom
docs/fix-resolve-dependency-api
Sep 6, 2026
Merged

docs: correct how modern_di_fixture resolves in the README API section#37
lesnik512 merged 1 commit into
mainfrom
docs/fix-resolve-dependency-api

Conversation

@lesnik512

Copy link
Copy Markdown
Member

The README's ## API section said modern_di_fixture resolves a type via
container.resolve and a Provider via container.resolve_provider. It does
neither: factory.py calls container.resolve_dependency(dependency), and the
type-or-provider dispatch happens inside modern-di.

Both methods still exist as public methods on Container in modern-di 3.4.0, so
nothing about the README was broken links or dead API — only the attribution of
which call this package makes. It went stale in 2.1.0, when the inline
isinstance dispatch was replaced by resolve_dependency
(planning/releases/2.1.0.md); the README was not updated alongside it.

The replacement names the one call this package makes and stops describing where
modern-di routes it from there.

Non-goals: the inject/register wording elsewhere in the README and in
factory.py docstrings is left alone — that belongs to the in-flight vocabulary
migration on docs/migrate-off-planning. This change touches lines that branch
does not.

Tiny lane: docs-only, no behaviour change, no change file. AGENTS.md and
architecture/ already describe the delegation correctly, so the README was the
only stale spot.

Verification: just lint-ci and just test-ci both pass (16 tests, 100%
coverage).

@lesnik512
lesnik512 merged commit 3f6b88a into main Sep 6, 2026
6 checks passed
@lesnik512
lesnik512 deleted the docs/fix-resolve-dependency-api branch September 6, 2026 18:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant