Skip to main content

Install

pip install -U git+https://github.com/mayank31313/python-dependency-injection.git

Documentation

Documentation is shifted here

Example

Follow the below code to simplify understanding, or can also refer to main.py

from cndi.annotations import Bean, Autowired, AppInitializer

class BeanTest:
    def __init__(self, name):
        self.name = name


@Bean()
def getTestBean() -> BeanTest:
    return BeanTest("Test 123")

testBean = None

app = AppInitializer()
if __name__ == "__main__":
    @Autowired()
    def setTestBean(bean: BeanTest):
        global testBean
        testBean = bean

    app.run()

    print(testBean.name)

Metadata

Release files for cndi 2.7.8

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

Source distribution (sdist)

Source distribution for cndi 2.7.8
File Size Uploaded Provenance Actions
cndi-2.7.8.tar.gz 31.2 kB Without provenance Details for cndi-2.7.8.tar.gz

Built distribution (wheel)

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

Total release size: 70.3 kB

Release files / cndi-2.7.8.tar.gz

Download URL cndi-2.7.8.tar.gz
Size 31.2 kB
Tags Source
SHA-256 checksum
How to use checksums
68920ddf6799fb62d59069348e463c0f3786fee925d8b07d38cc2924ae7827c8
BLAKE2b-256 checksum
How to use checksums
e090c8ecccb10a45244c8121fd0f87c7043975aa46fb36a5008022b7600d4cef
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.9.25

Release files / cndi-2.7.8-py3-none-any.whl

Download URL cndi-2.7.8-py3-none-any.whl
Size 39.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c959a220abbb0110ed2972b0dfefc4ed1b5117b64849cfa8824bed1807de21b7
BLAKE2b-256 checksum
How to use checksums
90b232fa2505099b0e73ee7c99c484b6ccbdab429e0eb6d76441399d516c018d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.9.25

Security for cndi 2.7.8

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.

Release history Release notifications | RSS feed

This release

2.7.8 This release

2 release files No provenance

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