Skip to main content

Simple Dependency Injection framework

Project description

"That Depends"

Test Coverage MyPy Strict pyrefly Supported versions PyPI Downloads GitHub stars libs.tech recommends llms.txt

Dependency injection framework for Python.

Starting a new project? Also consider modern-di, the newer DI framework from the same author with a smaller core and per-framework integration packages. that-depends remains fully supported — see Ecosystem below.

It is production-ready and gives you the following:

  • Simple async-first DI framework with IOC-container.
  • Python 3.10+ support.
  • Full coverage by types annotations (mypy in strict mode, pyrefly).
  • Inbuilt FastAPI, FastStream and LiteStar compatibility.
  • Dependency context management with scopes.
  • Overriding dependencies for tests.
  • Injecting dependencies in functions and coroutines without wiring.
  • Package with zero dependencies.

Installation

pip install that-depends

Ecosystem

that-depends is part of the modern-python family. If you're starting a new project, consider modern-di — the newer DI framework from the same author, with separate framework adapters:

that-depends remains actively maintained — see the migration guide if you want to move existing projects across.

📚 Documentation

📦 PyPi

📝 License

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

that_depends-4.0.0a2.tar.gz (31.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

that_depends-4.0.0a2-py3-none-any.whl (43.9 kB view details)

Uploaded Python 3

File details

Details for the file that_depends-4.0.0a2.tar.gz.

File metadata

  • Download URL: that_depends-4.0.0a2.tar.gz
  • Upload date:
  • Size: 31.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.19 {"installer":{"name":"uv","version":"0.11.19","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for that_depends-4.0.0a2.tar.gz
Algorithm Hash digest
SHA256 aca365a6cabb2a2c88eac99995f3aad6ca57321c55f9a0027c3eb274b330da68
MD5 d2d854858d47754ccbd8e771bd1947b5
BLAKE2b-256 355ee7dd9f12acade2efd8d53459246a0826464499ce4d7e431cffe9026b0e96

See more details on using hashes here.

File details

Details for the file that_depends-4.0.0a2-py3-none-any.whl.

File metadata

  • Download URL: that_depends-4.0.0a2-py3-none-any.whl
  • Upload date:
  • Size: 43.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.19 {"installer":{"name":"uv","version":"0.11.19","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for that_depends-4.0.0a2-py3-none-any.whl
Algorithm Hash digest
SHA256 e8b4742f03f5ef9a68dd5dea947352fe2b722056621df2c12f2a2e4ab304a059
MD5 b9789fb4a250d5ce41d3639ca2f9a26d
BLAKE2b-256 250642347c4bbd819a958b66ee053f02c3a514c44eee8efaecc37d80980e894d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page