Skip to main content

HinteDI - simple dependency injection system with type hints

This package is a small utility I have been using in my own projects, a super simple tool for basic dependency injection in python based on type hints and decorators.

This package exposes three classes: HinteDI, InjectionException and InstanceSentinel. Import HinteDI and use @HinteDI.singleton and @HinteDI.instance to create dependencies and @HinteDI.inject to mark a function as requiring dependency injection. Type hint the dependencies in the injected function and HinteDI will inject the dependencies for you. You can also use @HinteDI.abstract_base, @HinteDI.singleton_implementation and @HinteDI.instance_implementation to create factory-style abstract dependencies resolvable with a set key. See the docs at GitHub pages for better documentation about the package.

Metadata

Release files for HinteDI 0.3.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for HinteDI 0.3.2
File Size Uploaded Provenance Actions
HinteDI-0.3.2.tar.gz 8.6 kB Without provenance Details for HinteDI-0.3.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for HinteDI 0.3.2
File Interpreter ABI Platform Actions
HinteDI-0.3.2-py3-none-any.whl Python 3 none any Details for HinteDI-0.3.2-py3-none-any.whl

Total release size: 15.6 kB

Release files / HinteDI-0.3.2.tar.gz

Download URL HinteDI-0.3.2.tar.gz
Size 8.6 kB
Tags Source
SHA-256 checksum
How to use checksums
4c1371d3b7ffdf3e46ccf2488116e8e64cbc6d0d5abdd2c6b5d2941b8031eecd
BLAKE2b-256 checksum
How to use checksums
66b8ec30d64283aa69cfa1ba20e1d498a11c381a0e3d18fa6f7b0aed5f5e0bbd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.8.10

Release files / HinteDI-0.3.2-py3-none-any.whl

Download URL HinteDI-0.3.2-py3-none-any.whl
Size 7.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
383849e5d90859a7fb49aaca71aa6c0170d1039d456cdb85113ae6a6b9eba31f
BLAKE2b-256 checksum
How to use checksums
772960401a3903fec7ea64c023e3155e87e7284a238432de997de613338272db
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.8.10

Security for HinteDI 0.3.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page