Skip to content

chore: adopt modern-di 2.25 integration seams#4

Merged
lesnik512 merged 1 commit into
mainfrom
chore/adopt-2.25-seams
Jul 7, 2026
Merged

chore: adopt modern-di 2.25 integration seams#4
lesnik512 merged 1 commit into
mainfrom
chore/adopt-2.25-seams

Conversation

@lesnik512

Copy link
Copy Markdown
Member

Summary

  • Replace container.providers_registry.add_providers(...) reach-in in setup_di with the blessed container.add_providers(...) seam.
  • Replace the manual isinstance-on-AbstractProvider dispatch in _resolve_di_params with container.resolve_dependency(...); _FromDI marker unwrapping is unchanged.
  • Bump the modern-di floor to >=2.25.0,<3 (matches the existing X.Y.Z constraint style).
  • Update architecture/dependency-resolution.md to describe resolution via Container.resolve_dependency.

Upstream seam: modern-python/modern-di#283

Test plan

  • just lint-ci (eof-fixer, ruff format/check, ty, planning index)
  • just test-ci — 8 passed, 100% coverage

Replace the providers_registry reach-in with container.add_providers, and
the isinstance-on-AbstractProvider dispatch with container.resolve_dependency.
Bump the modern-di floor to >=2.25.0,<3.
@lesnik512 lesnik512 merged commit 5282ccb into main Jul 7, 2026
6 checks passed
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