We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow to set alias when entering scope. That will allow to change logic for specific route without moving it to container
with container(aliases={A: A1}) as request_container: request_container.get(A) # this will reuturn A1
Aliases should be copied to inner scopes if we do not know the scope of depedency. But the do not affect the outer scope.
The text was updated successfully, but these errors were encountered:
Alternative:
from enum import StrEnum from typing import Annotated class ProviderType(StrEnum): headers = "HEADERS" body = "BODY" class DIProvider(Provider): @provide() def get_provider() -> IdProvider: ... @provide(tags=[ProviderType.headers]) def get_provider() -> IdProvider: ... @inject(tags=[ProviderType.headers]) def func( id_provider: Annotated[IdProvider, Depends()], ): ...
Sorry, something went wrong.
No branches or pull requests
Allow to set alias when entering scope. That will allow to change logic for specific route without moving it to container
Aliases should be copied to inner scopes if we do not know the scope of depedency. But the do not affect the outer scope.
The text was updated successfully, but these errors were encountered: