Skip to content

Assert that the type of the parameter matches what is requested. #60

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
maldoinc opened this issue Mar 22, 2025 · 2 comments · May be fixed by #69
Open

Assert that the type of the parameter matches what is requested. #60

maldoinc opened this issue Mar 22, 2025 · 2 comments · May be fixed by #69
Assignees
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@maldoinc
Copy link
Owner

The container should throw if the type of the parameter does not match that of the argument.

E.g: Annotated[str, Inject(param="foo")] is requested but foo is actually an int.

@maldoinc maldoinc added enhancement New feature or request good first issue Good for newcomers labels Mar 22, 2025
@Keerthi421
Copy link

I would like to work on this issue @maldoinc

@maldoinc
Copy link
Owner Author

Hi. Thanks for offering to work on this. To get started: The validation code lives in the wireup.ioc.validation module. assert_dependency_exists is probably your starting point.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants