Skip to content

dependency_injector.wiring.Provide object at 0x... #589

New issue

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

Open
acscott opened this issue May 17, 2022 · 1 comment
Open

dependency_injector.wiring.Provide object at 0x... #589

acscott opened this issue May 17, 2022 · 1 comment

Comments

@acscott
Copy link

acscott commented May 17, 2022

Version 4.39.1
Instead of providing the configuration value it returns
<dependency_injector.wiring.Provide object at 0x...>

config is setup as shown
config = providers.Configuration( yaml_files="default.yaml") and default.yaml does exist.

and a call that relies on the dependency looks as below

@inject
def get_consistency_level( consistency_level: str = Provide["config.external.cassandra.parameters.consistency_level"],)

But consistency_level is set to <dependency_injector.wiring.Provide object at 0x7f9b1f9d8d60
Or in other words the dependency injection is not working.

Any tips on fixing this or how to go about debugging this?

@stevenengland
Copy link

I have the same issue here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants