wireup 2.9.0__tar.gz → 2.10.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {wireup-2.9.0 → wireup-2.10.0}/PKG-INFO +3 -3
- {wireup-2.9.0 → wireup-2.10.0}/docs/mkdocs.yml +2 -0
- wireup-2.10.0/docs/pages/class/fastapi_integration.md +8 -0
- wireup-2.10.0/docs/pages/class/starlette_integration.md +8 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/container.md +40 -19
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/index.md +5 -44
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/aiohttp/index.md +7 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/click/index.md +7 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/django/index.md +11 -1
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/fastapi/background_tasks.md +1 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/fastapi/index.md +8 -1
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/flask/index.md +7 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/starlette/background_tasks.md +1 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/typer/index.md +7 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/lifetimes_and_scopes.md +47 -1
- wireup-2.10.0/docs/pages/packaging_injectables.md +108 -0
- wireup-2.10.0/docs/pages/stylesheets/extra.css +32 -0
- wireup-2.10.0/docs/pages/testing.md +259 -0
- wireup-2.10.0/docs/pages/what_wireup_validates.md +352 -0
- wireup-2.10.0/pet_store_demo_app/README.md +20 -0
- wireup-2.10.0/pet_store_demo_app/__init__.py +1 -0
- wireup-2.10.0/pet_store_demo_app/cbr.py +29 -0
- wireup-2.10.0/pet_store_demo_app/factories.py +22 -0
- wireup-2.10.0/pet_store_demo_app/fastapi_services.py +29 -0
- wireup-2.10.0/pet_store_demo_app/flask_main.py +84 -0
- wireup-2.10.0/pet_store_demo_app/main.py +89 -0
- wireup-2.10.0/pet_store_demo_app/services/__init__.py +17 -0
- wireup-2.10.0/pet_store_demo_app/services/adoption.py +35 -0
- wireup-2.10.0/pet_store_demo_app/services/audit.py +21 -0
- wireup-2.10.0/pet_store_demo_app/services/infra.py +27 -0
- wireup-2.10.0/pet_store_demo_app/services/owners.py +28 -0
- wireup-2.10.0/pet_store_demo_app/services/pets.py +41 -0
- wireup-2.10.0/pet_store_demo_app/services/session.py +23 -0
- {wireup-2.9.0 → wireup-2.10.0}/pyproject.toml +1 -1
- {wireup-2.9.0 → wireup-2.10.0}/readme.md +2 -2
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/fastapi/test_fastapi_integration.py +99 -1
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/starlette/test_starlette_integration.py +102 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_container_scope.py +35 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_inject_from_container.py +26 -0
- {wireup-2.9.0 → wireup-2.10.0}/uv.lock +1 -1
- {wireup-2.9.0 → wireup-2.10.0}/wireup/__init__.py +4 -2
- {wireup-2.9.0 → wireup-2.10.0}/wireup/_decorators.py +19 -13
- {wireup-2.9.0 → wireup-2.10.0}/wireup/integration/starlette.py +12 -1
- {wireup-2.9.0 → wireup-2.10.0}/wireup/ioc/container/__init__.py +13 -2
- {wireup-2.9.0 → wireup-2.10.0}/wireup/ioc/container/async_container.py +10 -4
- {wireup-2.9.0 → wireup-2.10.0}/wireup/ioc/container/sync_container.py +5 -2
- {wireup-2.9.0 → wireup-2.10.0}/wireup/ioc/util.py +1 -1
- wireup-2.10.0/z_docs/.obsidian/appearance.json +3 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/.obsidian/workspace.json +24 -14
- wireup-2.10.0/z_docs/drafts/codex_r_fastapi_post copy.md +84 -0
- wireup-2.10.0/z_docs/drafts/codex_r_fastapi_post.md +81 -0
- wireup-2.10.0/z_docs/ideas/collection_injection_docs_draft.md +276 -0
- wireup-2.10.0/z_docs/ideas/config_and_qualified_type_sugar.md +98 -0
- wireup-2.10.0/z_docs/ideas/docs_map_for_default_llm_choice.md +323 -0
- wireup-2.10.0/z_docs/ideas/lazy.md +513 -0
- wireup-2.10.0/z_docs/ideas/mapping_collection_injection_api.md +469 -0
- wireup-2.10.0/z_docs/ideas/readme update - advanced section.md +12 -0
- wireup-2.10.0/z_docs/ideas/scoped_override.md +304 -0
- wireup-2.10.0/z_docs/ideas/tagged_collection_injection_sketch.md +527 -0
- wireup-2.10.0/z_docs/ideas/tmp_sequence_filter_demo.py +80 -0
- wireup-2.10.0/z_docs/ideas/wrap_with_dependencies.md +78 -0
- wireup-2.10.0/z_sugar.py +28 -0
- wireup-2.10.0/z_test.py +36 -0
- wireup-2.10.0/z_test_2.py +19 -0
- wireup-2.10.0/z_test_3.py +24 -0
- wireup-2.10.0/z_test_services/__init__.py +0 -0
- wireup-2.10.0/z_z.py +70 -0
- wireup-2.10.0/z_zz.py +105 -0
- wireup-2.9.0/.agent/rules.md +0 -3
- wireup-2.9.0/docs/pages/class/fastapi_integration.md +0 -3
- wireup-2.9.0/docs/pages/class/starlette_integration.md +0 -3
- wireup-2.9.0/docs/pages/stylesheets/extra.css +0 -83
- wireup-2.9.0/docs/pages/testing.md +0 -220
- wireup-2.9.0/z_docs/.obsidian/appearance.json +0 -3
- wireup-2.9.0/z_docs/drafts/codex_r_fastapi_post.md +0 -88
- wireup-2.9.0/z_docs/ideas/z_test_glm_testing_report.md +0 -479
- wireup-2.9.0/z_docs/ideas/z_test_new_integrations.md +0 -134
- wireup-2.9.0/z_test.py +0 -10
- wireup-2.9.0/z_test_2.8.0_release.md +0 -97
- {wireup-2.9.0/.agent → wireup-2.10.0/.agents}/workflows/context.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/.gitignore +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/10044845188665810066 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/10294724371649670728 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/1076323475707195139 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/11070404547826992651 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/11124823139456244859 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/11293014782143221354 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/1226111022864589093 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/12549328558144052424 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/1271758769353586558 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/12733979256433392731 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/12752882211929243556 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/12783426531917578909 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/12830345886006928062 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/13014544647268190247 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/13083424730640715152 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/13128933095426148813 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/13370773888390464336 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/13403801197489695949 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/1361555227596880095 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/13775377501054353309 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/1439640565749963662 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/14761872988004119841 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/14837314323412076685 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/15018906666218230475 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/15137346072215138130 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/15746470211891335948 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/16124785681570184387 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/16306461914818170209 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/17346873189989222451 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/17539328537605741444 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/1756490492350570913 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/17695288524157522424 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/17993352065017356676 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/2491296543125450213 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/2511243215163562241 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/2989687286403812976 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/3004183706503532835 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/3121150246064866450 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/3124270596782374079 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/3476900567878811119 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/3702806183923662406 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/4201971366852234974 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/4248594428038296655 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/4328746867122106743 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/453810864507090243 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/4607165423255654887 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/4655087458686603143 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/4911927025649090134 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/5545364815676479752 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/5582803025959560496 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/6446587083349335436 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/7197171008315212702 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/7815757281852325210 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/7940362391983581688 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/8465230536178924220 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/8499329960173449201 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/8504618348287803373 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/8761805547931915049 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/918853441261096549 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/9231702844672586930 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/9252445419859529063 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/9597896872206851048 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/9860729219353091761 +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.cache/9961436229075698645 +0 -0
- /wireup-2.9.0/benchmarks/wireup_benchmarks/__init__.py → /wireup-2.10.0/.codex +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.github/contributing.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.github/workflows/run_all.yml +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.github/workflows/run_integration_tests.yml +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.gitignore +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.vscode/launch.json +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/.vscode/settings.json +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/Makefile +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/bench_runner.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/benchmark_meta.json +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/benchmark_results.csv +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/benchmark_run_metrics.csv +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/generate_charts.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/generate_tables.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/generate_versions.py +0 -0
- {wireup-2.9.0/test → wireup-2.10.0/benchmarks/wireup_benchmarks}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/wireup_benchmarks/aioinject_setup.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/wireup_benchmarks/app.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/wireup_benchmarks/dependency_injector_setup.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/wireup_benchmarks/dishka_setup.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/wireup_benchmarks/diwire_setup.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/wireup_benchmarks/fastapi_setup.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/wireup_benchmarks/globals_setup.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/wireup_benchmarks/injector_setup.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/wireup_benchmarks/lagom_setup.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/wireup_benchmarks/services.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/wireup_benchmarks/svcs_setup.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/wireup_benchmarks/that_depends_setup.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/wireup_benchmarks/wireup_cbr_setup.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/benchmarks/wireup_benchmarks/wireup_setup.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/.cache/.gitignore +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/overrides/main.html +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/benchmarks.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/class/aiohttp_integration.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/class/asgi_integration.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/class/celery_integration.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/class/click_integration.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/class/config_store.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/class/django_integration.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/class/fastmcp_integration.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/class/flask_integration.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/class/override_manager.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/class/typer_integration.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/class/wireup.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/conditional_registration.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/configuration.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/factories.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/function_injection.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/generic_dependencies.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/getting_started.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/img/benchmarks_scoped_dark.svg +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/img/benchmarks_scoped_light.svg +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/img/benchmarks_singleton_dark.svg +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/img/benchmarks_singleton_light.svg +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/injectables.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/aiohttp/class_based_handlers.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/asgi/generic_asgi.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/celery/index.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/django/app_injection.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/django/request_time_injection.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/django/setup.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/django/testing.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/django/troubleshooting.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/django/view_injection.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/fastapi/class_based_handlers.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/fastapi/context_in_services.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/fastapi/inject_in_routes.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/fastapi/request_time_injection.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/fastapi/testing.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/fastapi/troubleshooting.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/fastmcp/index.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/index.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/starlette/index.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/integrations/strawberry/index.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/interfaces.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/migrate_to_wireup/dependency_injector.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/migrate_to_wireup/fastapi_depends.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/migrate_to_wireup/index.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/resources.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/reusable_bundles.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/upgrading.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/docs/pages/versioning.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/license.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/profile_tests.py +0 -0
- {wireup-2.9.0/test/integration → wireup-2.10.0/test}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/conftest.py +0 -0
- {wireup-2.9.0/test/integration/aiohttp → wireup-2.10.0/test/integration}/__init__.py +0 -0
- {wireup-2.9.0/test/integration/click → wireup-2.10.0/test/integration/aiohttp}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/aiohttp/handler.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/aiohttp/routes.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/aiohttp/services.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/aiohttp/test_aiohttp_integration.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/asgi/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/asgi/test_asgi_integration.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/celery/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/celery/test_celery_integration.py +0 -0
- {wireup-2.9.0/test/integration/django → wireup-2.10.0/test/integration/click}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/click/test_click_integration.py +0 -0
- {wireup-2.9.0/test/integration/django/apps → wireup-2.10.0/test/integration/django}/__init__.py +0 -0
- {wireup-2.9.0/test/integration/django/apps/app_1 → wireup-2.10.0/test/integration/django/apps}/__init__.py +0 -0
- {wireup-2.9.0/test/integration/django/apps/app_2 → wireup-2.10.0/test/integration/django/apps/app_1}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/apps/app_1/app.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/apps/app_1/management/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/apps/app_1/management/commands/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/apps/app_1/management/commands/wireup_greet.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/apps/app_1/urls.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/apps/app_1/views.py +0 -0
- {wireup-2.9.0/test/integration/django/apps/drf_app → wireup-2.10.0/test/integration/django/apps/app_2}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/apps/app_2/app.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/apps/app_2/urls.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/apps/app_2/views.py +0 -0
- {wireup-2.9.0/test/integration/django/apps/ninja_app → wireup-2.10.0/test/integration/django/apps/drf_app}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/apps/drf_app/app.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/apps/drf_app/urls.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/apps/drf_app/views.py +0 -0
- {wireup-2.9.0/test/integration/django/factory → wireup-2.10.0/test/integration/django/apps/ninja_app}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/apps/ninja_app/app.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/apps/ninja_app/urls.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/apps/ninja_app/views.py +0 -0
- {wireup-2.9.0/test/integration/django/injectable → wireup-2.10.0/test/integration/django/factory}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/factory/factories.py +0 -0
- {wireup-2.9.0/test/integration/fastapi → wireup-2.10.0/test/integration/django/injectable}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/injectable/current_request_service.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/injectable/random_service.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/templates/bar.html +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/templates/foo.html +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/test_django_integration.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/django/view.py +0 -0
- {wireup-2.9.0/test/integration/flask → wireup-2.10.0/test/integration/fastapi}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/fastapi/cbr.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/fastapi/router.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/fastapi/services.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/fastapi/test_fastapi_codegen_snapshots.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/fastapi/wireup_route.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/fastmcp/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/fastmcp/test_fastmcp_standalone_usage.py +0 -0
- {wireup-2.9.0/test/integration/flask/services → wireup-2.10.0/test/integration/flask}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/flask/bp.py +0 -0
- {wireup-2.9.0/test/integration/starlette → wireup-2.10.0/test/integration/flask/services}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/flask/services/factories.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/flask/services/is_test_service.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/flask/test_flask_integration.py +0 -0
- {wireup-2.9.0/test/shared → wireup-2.10.0/test/integration/starlette}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/strawberry/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/strawberry/test_strawberry_django_usage.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/strawberry/test_strawberry_fastapi_usage.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/strawberry/test_strawberry_starlette_usage.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/typer/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/integration/typer/test_typer_integration.py +0 -0
- {wireup-2.9.0/test/shared/shared_services → wireup-2.10.0/test/shared}/__init__.py +0 -0
- {wireup-2.9.0/test/unit → wireup-2.10.0/test/shared/shared_services}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/shared/shared_services/greeter.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/shared/shared_services/rand.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/shared/shared_services/scoped.py +0 -0
- {wireup-2.9.0/test/unit/services/no_annotations/random → wireup-2.10.0/test/unit}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/service_refs/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/services/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/services/abstract_multiple_bases.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/services/async_reg.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/services/inheritance_test/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/services/inheritance_test/base.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/services/no_annotations/__init__.py +0 -0
- {wireup-2.9.0/test/unit/services/with_annotations → wireup-2.10.0/test/unit/services/no_annotations/random}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/services/no_annotations/random/random_service.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/services/no_annotations/random/truly_random_service.py +0 -0
- {wireup-2.9.0/wireup/integration → wireup-2.10.0/test/unit/services/with_annotations}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/services/with_annotations/env/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/services/with_annotations/services.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_as_type.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_compiler_code_generation.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_concurrency.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_container_core.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_container_creation.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_container_generator_factory.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_container_override.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_eval_type.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_exit_stack.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_inject_from_container_optional_types.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_inject_from_container_stringified_types.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_instance.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_module_loading.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_optional_type.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_parameter.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_pos_only_validation.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_service_deprecation.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_service_registry.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_signature_hiding.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_type_analysis.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/test_util.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/test/unit/util.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/tox.ini +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/_annotations.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/_discovery.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/_instance.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/_wrapper_compiler.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/codegen.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/errors.py +0 -0
- {wireup-2.9.0/wireup/ioc → wireup-2.10.0/wireup/integration}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/integration/aiohttp.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/integration/asgi.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/integration/celery.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/integration/click.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/integration/django/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/integration/django/apps.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/integration/django/decorators.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/integration/fastapi.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/integration/fastmcp.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/integration/flask.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/integration/typer.py +0 -0
- {wireup-2.9.0/z_prep → wireup-2.10.0/wireup/ioc}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/ioc/_exit_stack.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/ioc/configuration.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/ioc/container/base_container.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/ioc/container/lock_registry.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/ioc/dependency_introspection.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/ioc/factory_compiler.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/ioc/override_manager.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/ioc/registry.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/ioc/registry_validation.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/ioc/type_analysis.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/ioc/types.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/py.typed +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/wireup/util.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/.obsidian/app.json +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/.obsidian/core-plugins.json +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/drafts/codex_djangoforum.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/drafts/codex_fastmcp_post.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/drafts/coxed_fastapi_discussion.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/drafts/coxed_fastmcp_post.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/drafts/coxed_strawberry_discussion.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/drafts/dodona_march_en.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/drafts/hrt.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/drafts/open_generics.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/ideas/nested scopes.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/ideas/post_aggregates_followups.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/ideas/transactional.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/ideas/wireup_provided.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/ideas/z_test_community_engagement.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/ideas/z_test_dependency_injector.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/ideas/z_test_seo_plan.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/ideas/z_test_wireup_seo_plan_2026.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_docs/style/docs_voice.md +0 -0
- {wireup-2.9.0/z_test_services → wireup-2.10.0/z_prep}/__init__.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/js_stack.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_cit_code1.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_cit_code2.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_cit_palindrome.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_citadel_oa1.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt10.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt11.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt12.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt13.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt14.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt15.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt16.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt17.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt18.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt2.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt3.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt4.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt5.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt6.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt7.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt8.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_hrt9.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_js_code1.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_js_code2.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_prep/z_test_py.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_test_benchmark.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_test_bug.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_test_dict.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_test_fastapi.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_test_get_typeform.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_test_hash.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_test_inject_from_container.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_test_instance.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_test_leetcode_arrays_lists.md +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_test_misc.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_test_provider_style.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_test_reusable.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_test_services/bar.py +0 -0
- {wireup-2.9.0 → wireup-2.10.0}/z_test_services/foo.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: wireup
|
|
3
|
-
Version: 2.
|
|
3
|
+
Version: 2.10.0
|
|
4
4
|
Summary: Python Dependency Injection Library
|
|
5
5
|
Project-URL: Homepage, https://github.com/maldoinc/wireup
|
|
6
6
|
Project-URL: Repository, https://github.com/maldoinc/wireup
|
|
@@ -67,7 +67,7 @@ Reuse the same application code in APIs, CLIs, workers, and scripts without rewr
|
|
|
67
67
|
</td>
|
|
68
68
|
<td align="center" valign="top" width="33%">
|
|
69
69
|
<h3>✅ Correct by Default</h3>
|
|
70
|
-
If the container starts, your dependency graph is valid. Wireup checks for missing or misconfigured dependencies to avoid surprises at runtime.
|
|
70
|
+
If the container starts, your dependency graph is valid. Wireup checks for missing or misconfigured dependencies to avoid surprises at runtime. See <a href="https://maldoinc.github.io/wireup/latest/what_wireup_validates/">What Wireup Validates</a>
|
|
71
71
|
</td>
|
|
72
72
|
<td align="center" valign="top" width="33%">
|
|
73
73
|
<h3>🌐 Framework-Ready</h3>
|
|
@@ -311,7 +311,7 @@ class OrderProcessor:
|
|
|
311
311
|
|
|
312
312
|
### 🛡️ Startup Validation
|
|
313
313
|
|
|
314
|
-
Wireup validates the dependency graph when the container is created.
|
|
314
|
+
Wireup validates the dependency graph when the container is created. See <a href="https://maldoinc.github.io/wireup/latest/what_wireup_validates/">What Wireup Validates</a> for the full rules and limits.
|
|
315
315
|
|
|
316
316
|
```python
|
|
317
317
|
# Missing dependencies: caught at startup, not at runtime
|
|
@@ -20,7 +20,9 @@ nav:
|
|
|
20
20
|
- Conditional Registration: conditional_registration.md
|
|
21
21
|
- Generic Dependencies: generic_dependencies.md
|
|
22
22
|
- Guides:
|
|
23
|
+
- Packaging Injectables: packaging_injectables.md
|
|
23
24
|
- Testing: testing.md
|
|
25
|
+
- What Wireup Validates: what_wireup_validates.md
|
|
24
26
|
- Upgrading: upgrading.md
|
|
25
27
|
- Versioning: versioning.md
|
|
26
28
|
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
## wireup.integration.fastapi
|
|
2
|
+
|
|
3
|
+
::: wireup.integration.fastapi
|
|
4
|
+
|
|
5
|
+
!!! note
|
|
6
|
+
For best performance with `WireupTask`, prefer regular top-level functions for background task callbacks.
|
|
7
|
+
Wireup creates cached injection wrappers for top-level functions, but callable objects and nested
|
|
8
|
+
functions/closures do not benefit from that caching.
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
## wireup.integration.flask
|
|
2
|
+
|
|
3
|
+
::: wireup.integration.starlette
|
|
4
|
+
|
|
5
|
+
!!! note
|
|
6
|
+
For best performance with `WireupTask`, prefer regular top-level functions for background task callbacks.
|
|
7
|
+
Wireup creates cached injection wrappers for top-level functions, but callable objects and nested
|
|
8
|
+
functions/closures do not benefit from that caching.
|
|
@@ -129,41 +129,62 @@ db_url = container.config.get("database_url")
|
|
|
129
129
|
|
|
130
130
|
Prefer `Inject(config="key")` in dependency constructors over accessing `container.config` directly.
|
|
131
131
|
|
|
132
|
+
|
|
133
|
+
### `override`
|
|
134
|
+
|
|
135
|
+
Substitute dependencies for testing. Access via `container.override`.
|
|
136
|
+
|
|
137
|
+
```python
|
|
138
|
+
with container.override.injectable(target=Database, new=mock_db):
|
|
139
|
+
... # All injections of Database use mock_db
|
|
140
|
+
```
|
|
141
|
+
|
|
142
|
+
See [Testing](testing.md) for details.
|
|
143
|
+
|
|
144
|
+
|
|
132
145
|
## Injecting The Container
|
|
133
146
|
|
|
134
|
-
|
|
135
|
-
|
|
147
|
+
The container can inject itself just like any other dependency. This is an advanced feature for infrastructure code that needs runtime container access. This pattern is generally not recommended for regular injectables when you know the required dependencies ahead of time.
|
|
148
|
+
|
|
149
|
+
Depend on the root container by type:
|
|
150
|
+
|
|
151
|
+
- `SyncContainer`, `ScopedSyncContainer` when using a synchronous container created via `wireup.create_sync_container`
|
|
152
|
+
- `AsyncContainer`, `ScopedAsyncContainer` when using an asynchronous container created via `wireup.create_async_container`
|
|
153
|
+
|
|
154
|
+
Typical examples include:
|
|
155
|
+
|
|
156
|
+
- Selecting a handler or implementation at runtime based on a qualifier or runtime data
|
|
157
|
+
- Wrapping background tasks or callbacks so they run with Wireup injection
|
|
158
|
+
- Coordinating fan-out work across child scopes while letting services inside each child scope access that child scope
|
|
159
|
+
- Loading optional integrations only when a feature is enabled
|
|
136
160
|
|
|
137
161
|
```python
|
|
138
|
-
from wireup import injectable
|
|
139
|
-
from wireup.ioc.container.sync_container import SyncContainer
|
|
162
|
+
from wireup import SyncContainer, injectable
|
|
140
163
|
|
|
141
164
|
|
|
142
165
|
@injectable
|
|
143
|
-
class
|
|
166
|
+
class BackgroundTaskScheduler:
|
|
144
167
|
def __init__(self, container: SyncContainer) -> None:
|
|
145
168
|
self.container = container
|
|
146
169
|
```
|
|
147
170
|
|
|
148
|
-
|
|
149
|
-
access to the container. For a full example of wrapping callables dynamically, see
|
|
150
|
-
[Function Injection: Dynamic Function Injection](function_injection.md#dynamic-function-injection).
|
|
171
|
+
If you need the active scope rather than the root container, depend on the scoped container type:
|
|
151
172
|
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
Prefer regular constructor injection for application services. Inject the container only for advanced scenarios
|
|
155
|
-
where you truly need runtime access to it.
|
|
156
|
-
|
|
157
|
-
### `override`
|
|
173
|
+
```python
|
|
174
|
+
from wireup import ScopedSyncContainer, injectable
|
|
158
175
|
|
|
159
|
-
Substitute dependencies for testing. Access via `container.override`.
|
|
160
176
|
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
177
|
+
@injectable(lifetime="scoped")
|
|
178
|
+
class JobDispatcher:
|
|
179
|
+
def __init__(self, scope: ScopedSyncContainer) -> None:
|
|
180
|
+
self.scope = scope
|
|
164
181
|
```
|
|
165
182
|
|
|
166
|
-
|
|
183
|
+
For a full example of wrapping callables dynamically, see
|
|
184
|
+
[Function Injection: Dynamic Function Injection](function_injection.md#dynamic-function-injection). For examples of
|
|
185
|
+
passing selected dependencies into child scopes, see
|
|
186
|
+
[Lifetimes & Scopes: Sharing Context Across Scopes](lifetimes_and_scopes.md#sharing-context-across-scopes).
|
|
187
|
+
|
|
167
188
|
|
|
168
189
|
## Eager Initialization
|
|
169
190
|
|
|
@@ -21,7 +21,7 @@ and designed to fail fast: **if the container starts, it works**.
|
|
|
21
21
|
Wireup catches missing dependencies, circular references, lifetime mismatches, duplicate registrations, and missing
|
|
22
22
|
config keys at startup. Shared dependencies are created in a thread-safe way.
|
|
23
23
|
|
|
24
|
-
[:octicons-arrow-right-24:
|
|
24
|
+
[:octicons-arrow-right-24: What Wireup Validates](what_wireup_validates.md)
|
|
25
25
|
|
|
26
26
|
- :material-share-variant:{ .lg .middle } __Define Once, Inject Anywhere__
|
|
27
27
|
|
|
@@ -237,50 +237,11 @@ pip install wireup
|
|
|
237
237
|
|
|
238
238
|
## Validation checks
|
|
239
239
|
|
|
240
|
-
Wireup validates
|
|
240
|
+
Wireup validates the dependency graph up front and applies the same checks to injection targets it can inspect during
|
|
241
|
+
setup. That includes missing dependencies, missing config keys, circular dependencies, lifetime mismatches, and
|
|
242
|
+
duplicate registrations.
|
|
241
243
|
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
```python
|
|
245
|
-
@injectable
|
|
246
|
-
class Foo:
|
|
247
|
-
def __init__(self, oops: UnknownDep) -> None: ...
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
container = wireup.create_sync_container(injectables=[Foo])
|
|
251
|
-
# ❌ Parameter 'oops' of 'Foo' depends on an unknown injectable 'UnknownDep'.
|
|
252
|
-
```
|
|
253
|
-
|
|
254
|
-
=== "Function injection"
|
|
255
|
-
|
|
256
|
-
```python
|
|
257
|
-
container = wireup.create_sync_container(injectables=[])
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
@inject_from_container(container)
|
|
261
|
-
def my_function(oops: Injected[UnknownDep]) -> None: ...
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
# ❌ Parameter 'oops' of 'my_function' depends on an unknown injectable 'UnknownDep'.
|
|
265
|
-
```
|
|
266
|
-
|
|
267
|
-
=== "Configuration"
|
|
268
|
-
|
|
269
|
-
```python
|
|
270
|
-
@injectable
|
|
271
|
-
class Database:
|
|
272
|
-
def __init__(
|
|
273
|
-
self, url: Annotated[str, Inject(config="db_url")]
|
|
274
|
-
) -> None: ...
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
container = wireup.create_sync_container(injectables=[Database], config={})
|
|
278
|
-
# ❌ Parameter 'url' of Type 'Database' depends on an unknown Wireup config key 'db_url'.
|
|
279
|
-
```
|
|
280
|
-
|
|
281
|
-
Additional checks include circular dependencies, lifetime mismatches, and duplicate registrations. See
|
|
282
|
-
[Container](container.md), [Configuration](configuration.md), and [Function Injection](function_injection.md) for
|
|
283
|
-
details.
|
|
244
|
+
See [What Wireup Validates](what_wireup_validates.md) for a detailed explanation.
|
|
284
245
|
|
|
285
246
|
## Next Steps
|
|
286
247
|
|
|
@@ -186,6 +186,13 @@ async def users_list(
|
|
|
186
186
|
pass
|
|
187
187
|
```
|
|
188
188
|
|
|
189
|
+
### Dependency Validation
|
|
190
|
+
|
|
191
|
+
The aiohttp integration validates handlers during app startup.
|
|
192
|
+
Missing dependencies and config values fail before requests are served.
|
|
193
|
+
|
|
194
|
+
See [What Wireup Validates](../../what_wireup_validates.md) for the full rules.
|
|
195
|
+
|
|
189
196
|
### API Reference
|
|
190
197
|
|
|
191
198
|
- [aiohttp_integration](../../class/aiohttp_integration.md)
|
|
@@ -100,6 +100,13 @@ def test_random_number_command():
|
|
|
100
100
|
assert "Your lucky number is:" in result.output
|
|
101
101
|
```
|
|
102
102
|
|
|
103
|
+
### Dependency Validation
|
|
104
|
+
|
|
105
|
+
`wireup.integration.click.setup(...)` validates command callbacks during setup.
|
|
106
|
+
Missing dependencies and config values fail before commands are invoked.
|
|
107
|
+
|
|
108
|
+
See [What Wireup Validates](../../what_wireup_validates.md) for the full rules.
|
|
109
|
+
|
|
103
110
|
### API Reference
|
|
104
111
|
|
|
105
112
|
Visit [API Reference](../../class/click_integration.md) for detailed information about the Click integration module.
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
description: Django dependency injection with Wireup: a type-safe DI container for Django, DRF, and Ninja with setup, request/app injection patterns, testing, and troubleshooting.
|
|
3
3
|
---
|
|
4
4
|
|
|
5
|
-
# :simple-django: Django Integration
|
|
5
|
+
# :simple-django:{.color-django} Django Integration
|
|
6
6
|
|
|
7
7
|
<div class="grid cards annotate" markdown>
|
|
8
8
|
|
|
@@ -106,6 +106,16 @@ urlpatterns = [
|
|
|
106
106
|
|
|
107
107
|
Run the app with `python manage.py runserver`, then open `http://127.0.0.1:8000/greet/?name=World`.
|
|
108
108
|
|
|
109
|
+
## Dependency Validation
|
|
110
|
+
|
|
111
|
+
When `auto_inject_views=True`, Wireup validates Django views during app setup.
|
|
112
|
+
Missing dependencies and config values fail before requests are served.
|
|
113
|
+
|
|
114
|
+
When you use `@inject` or `@inject_app` explicitly, validation happens when those callables are invoked,
|
|
115
|
+
not as part of the root Django startup guarantee.
|
|
116
|
+
|
|
117
|
+
See [What Wireup Validates](../../what_wireup_validates.md) for the full rules.
|
|
118
|
+
|
|
109
119
|
## Detailed Guides
|
|
110
120
|
|
|
111
121
|
- [Django Setup and Installation](setup.md): installation, middleware placement, and settings/config integration.
|
|
@@ -4,6 +4,7 @@ Use `WireupTask` when you want Wireup to resolve dependencies inside a FastAPI b
|
|
|
4
4
|
|
|
5
5
|
## Usage
|
|
6
6
|
|
|
7
|
+
1. Add `wireup.integration.fastapi` to your Wireup injectables.
|
|
7
8
|
1. Define your task function with `Injected[...]` parameters for any Wireup dependencies
|
|
8
9
|
1. Inject `WireupTask` in your route handler: `wireup_task: Injected[WireupTask]`
|
|
9
10
|
1. Wrap the task function before scheduling: `wireup_task(write_greeting)`
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
description: FastAPI dependency injection with Wireup: type-safe DI for routes, WebSockets, request-time injection, class-based handlers, and background tasks.
|
|
3
3
|
---
|
|
4
4
|
|
|
5
|
-
# :simple-fastapi: FastAPI Integration
|
|
5
|
+
# :simple-fastapi:{.color-fastapi} FastAPI Integration
|
|
6
6
|
|
|
7
7
|
<div class="grid cards annotate" markdown>
|
|
8
8
|
|
|
@@ -86,6 +86,13 @@ Run the server with:
|
|
|
86
86
|
fastapi dev main.py
|
|
87
87
|
```
|
|
88
88
|
|
|
89
|
+
## Dependency Validation
|
|
90
|
+
|
|
91
|
+
`wireup.integration.fastapi.setup(...)` validates route handlers up front.
|
|
92
|
+
For regular route handlers, missing dependencies and config values fail during setup. For Class-based handlers, they fail during app startup.
|
|
93
|
+
|
|
94
|
+
See [What Wireup Validates](../../what_wireup_validates.md) for the full rules.
|
|
95
|
+
|
|
89
96
|
## Detailed Guides
|
|
90
97
|
|
|
91
98
|
- [Inject in Routes](inject_in_routes.md): HTTP/WebSocket handler injection and config value injection in route signatures.
|
|
@@ -104,6 +104,13 @@ See
|
|
|
104
104
|
[Flask integration tests](https://github.com/maldoinc/wireup/blob/master/test/integration/flask/test_flask_integration.py)
|
|
105
105
|
for more examples.
|
|
106
106
|
|
|
107
|
+
### Dependency Validation
|
|
108
|
+
|
|
109
|
+
`wireup.integration.flask.setup(...)` validates the views it wraps up front.
|
|
110
|
+
Missing dependencies and config values fail during setup.
|
|
111
|
+
|
|
112
|
+
See [What Wireup Validates](../../what_wireup_validates.md) for the full rules.
|
|
113
|
+
|
|
107
114
|
### API Reference
|
|
108
115
|
|
|
109
116
|
- [flask_integration](../../class/flask_integration.md)
|
|
@@ -4,6 +4,7 @@ Use `WireupTask` when you want Wireup to resolve dependencies inside a Starlette
|
|
|
4
4
|
|
|
5
5
|
## Usage
|
|
6
6
|
|
|
7
|
+
1. Add `wireup.integration.starlette` to your Wireup injectables.
|
|
7
8
|
1. Define your task function with `Injected[...]` parameters for any Wireup dependencies
|
|
8
9
|
1. Inject `WireupTask` in your route handler: `wireup_task: Injected[WireupTask]`
|
|
9
10
|
1. Wrap the task function before scheduling: `wireup_task(write_greeting)`
|
|
@@ -54,6 +54,13 @@ from wireup.integration.typer import get_app_container
|
|
|
54
54
|
container = get_app_container(app)
|
|
55
55
|
```
|
|
56
56
|
|
|
57
|
+
### Dependency Validation
|
|
58
|
+
|
|
59
|
+
`wireup.integration.typer.setup(...)` validates command callbacks during setup.
|
|
60
|
+
Missing dependencies and config values fail during setup.
|
|
61
|
+
|
|
62
|
+
See [What Wireup Validates](../../what_wireup_validates.md) for the full rules.
|
|
63
|
+
|
|
57
64
|
### API Reference
|
|
58
65
|
|
|
59
66
|
Visit [API Reference](../../class/typer_integration.md) for detailed information about the Typer integration module.
|
|
@@ -261,7 +261,53 @@ async def main():
|
|
|
261
261
|
await asyncio.gather(*tasks)
|
|
262
262
|
```
|
|
263
263
|
|
|
264
|
-
|
|
264
|
+
Services resolved inside a child scope can also depend on the active scoped container directly:
|
|
265
|
+
|
|
266
|
+
```python
|
|
267
|
+
from wireup import ScopedAsyncContainer, injectable
|
|
268
|
+
|
|
269
|
+
|
|
270
|
+
@injectable(lifetime="scoped")
|
|
271
|
+
class WorkerService:
|
|
272
|
+
def __init__(
|
|
273
|
+
self, scope: ScopedAsyncContainer, request_ctx: RequestContext
|
|
274
|
+
) -> None:
|
|
275
|
+
self.scope = scope
|
|
276
|
+
self.request_ctx = request_ctx
|
|
277
|
+
```
|
|
278
|
+
|
|
279
|
+
### Abstractions and Qualifiers
|
|
280
|
+
|
|
281
|
+
When using abstractions via `as_type` or qualifiers, the provided keys must match the registered dependency keys. For example, if you have:
|
|
282
|
+
|
|
283
|
+
```python
|
|
284
|
+
@injectable(as_type=Cache)
|
|
285
|
+
class RedisCache(Cache): ...
|
|
286
|
+
```
|
|
287
|
+
|
|
288
|
+
Then you must provide the instance using the `Cache` key, not `RedisCache`:
|
|
289
|
+
|
|
290
|
+
```python
|
|
291
|
+
provided = {
|
|
292
|
+
Cache: RedisCache(...), # Use the abstraction key, not the concrete class
|
|
293
|
+
}
|
|
294
|
+
```
|
|
295
|
+
|
|
296
|
+
With qualifiers, you must also include the qualifier in the key:
|
|
297
|
+
|
|
298
|
+
```python
|
|
299
|
+
@injectable(as_type=Cache, qualifier="in_memory")
|
|
300
|
+
class InMemoryCache(Cache): ...
|
|
301
|
+
```
|
|
302
|
+
Then the provided key must include the qualifier:
|
|
303
|
+
|
|
304
|
+
```python
|
|
305
|
+
provided = {
|
|
306
|
+
wireup.qualified(Cache, "in_memory"): InMemoryCache(...),
|
|
307
|
+
}
|
|
308
|
+
```
|
|
309
|
+
|
|
310
|
+
### Guidelines for what to share
|
|
265
311
|
|
|
266
312
|
- Good candidates: `RequestContext`, tenant/account context, auth claims, correlation/tracing metadata, immutable per-request flags.
|
|
267
313
|
- Usually avoid sharing: DB transactions, unit-of-work objects.
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
Use this guide when you want to package and distribute injectables across applications, teams, or internal
|
|
2
|
+
libraries. Wireup always receives a list of injectables, so the main choice is how your package exposes that
|
|
3
|
+
list.
|
|
4
|
+
|
|
5
|
+
## 1. Export A Module Or Package
|
|
6
|
+
|
|
7
|
+
Use this when the injectables are fixed and the application does not need to choose between variants.
|
|
8
|
+
Wireup's own integrations use the same idea. For example, `wireup.integration.fastapi` is a module with injectables that can be passed directly in `injectables=[...]` and exposes FastAPI `Request`, `WebSocket`, and `WireupTask`.
|
|
9
|
+
|
|
10
|
+
Example:
|
|
11
|
+
|
|
12
|
+
```python title="team_name_sqlalchemy/__init__.py"
|
|
13
|
+
@injectable
|
|
14
|
+
def database_session() -> DatabaseSession: ...
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
@injectable
|
|
18
|
+
class UserRepository: ...
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
```python title="app.py"
|
|
22
|
+
import wireup
|
|
23
|
+
import team_name_sqlalchemy
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
container = wireup.create_sync_container(
|
|
27
|
+
injectables=[team_name_sqlalchemy],
|
|
28
|
+
)
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
This is the simplest option. It works well for internal packages and libraries with a single default setup.
|
|
32
|
+
|
|
33
|
+
## 2. Export A List Of Injectables
|
|
34
|
+
|
|
35
|
+
Use this when you want the package to export an explicit list of injectables instead of relying on module
|
|
36
|
+
scanning.
|
|
37
|
+
|
|
38
|
+
```python title="team_name_sqlalchemy/__init__.py"
|
|
39
|
+
@injectable
|
|
40
|
+
def database_session() -> DatabaseSession: ...
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
@injectable
|
|
44
|
+
class UserRepository: ...
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
INJECTABLES = [database_session, UserRepository]
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
```python title="app.py"
|
|
51
|
+
import wireup
|
|
52
|
+
import team_name_sqlalchemy
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
container = wireup.create_sync_container(
|
|
56
|
+
injectables=[*team_name_sqlalchemy.INJECTABLES],
|
|
57
|
+
)
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
## 3. Export A Function That Returns Injectables
|
|
61
|
+
|
|
62
|
+
Use this when the package exposes parameters of its own, such as backend choices or feature flags.
|
|
63
|
+
|
|
64
|
+
```python title="team_name_sqlalchemy/__init__.py"
|
|
65
|
+
from typing import Literal, Protocol
|
|
66
|
+
|
|
67
|
+
from wireup import injectable
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
class Cache(Protocol): ...
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
@injectable(as_type=Cache)
|
|
74
|
+
class RedisCache: ...
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
@injectable(as_type=Cache)
|
|
78
|
+
class MemcachedCache: ...
|
|
79
|
+
|
|
80
|
+
|
|
81
|
+
def make_injectables(
|
|
82
|
+
*,
|
|
83
|
+
backend: Literal["redis", "memcached"],
|
|
84
|
+
) -> list[object]:
|
|
85
|
+
if backend == "redis":
|
|
86
|
+
return [RedisCache]
|
|
87
|
+
|
|
88
|
+
return [MemcachedCache]
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
```python title="app.py"
|
|
92
|
+
import wireup
|
|
93
|
+
from team_name_sqlalchemy import make_injectables
|
|
94
|
+
|
|
95
|
+
|
|
96
|
+
container = wireup.create_sync_container(
|
|
97
|
+
injectables=[*make_injectables(backend=settings.cache_backend)],
|
|
98
|
+
)
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
For reusable provider-style bundles or registering the same subgraph more than once, see
|
|
102
|
+
[Reusable Bundles](reusable_bundles.md).
|
|
103
|
+
|
|
104
|
+
## Which One Should You Pick?
|
|
105
|
+
|
|
106
|
+
- Use a module when the package has one setup and consumers do not need to choose between variants.
|
|
107
|
+
- Use a list when you want explicit control over what gets registered without module scanning.
|
|
108
|
+
- Use a function when the package exposes parameters that consumers must provide when building the injectables.
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
.md-header,
|
|
2
|
+
.md-tabs {
|
|
3
|
+
background-color: #242b3f;
|
|
4
|
+
}
|
|
5
|
+
|
|
6
|
+
.md-typeset {
|
|
7
|
+
font-size: .7rem;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.highlight {
|
|
11
|
+
font-size: .75rem;
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
body[data-md-color-scheme="default"] .grid.cards>ul>li {
|
|
15
|
+
border: 1px solid #ddd !important;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
body[data-md-color-scheme="slate"] .grid.cards>ul>li {
|
|
19
|
+
border: 1px solid var(--md-default-fg-color--lightest) !important;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.grid.cards>ul>li span.twemoji {
|
|
23
|
+
vertical-align: top !important;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
.color-fastapi {
|
|
27
|
+
color: rgb(0, 148, 133) !important
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.color-django {
|
|
31
|
+
color: #0C4B33 !important;
|
|
32
|
+
}
|