-
-
Notifications
You must be signed in to change notification settings - Fork 837
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
Optional string parameter causing resolution exception when AnyConcreteTypeNotAlreadyRegisteredSource added #728
Labels
Comments
Unit tests mentioned in post:
|
The
To:
The same issue is not present with an optional |
Fixed by PR #785. Woohoo! |
Fix included in v4.1.1, pushed to NuGet. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
From Google Group:
https://groups.google.com/forum/#!topic/autofac/lUZ6KAT7xXM
Hi there
I need to use the
AnyConcreteTypeNotAlreadyRegisteredSource
, to avoid having to explicitly register every concrete type we use.Unfortunately, I'm having a real issue attempting to use it when we have classes with optional string constructor parameters.
e.g.
It throws an error
I've attached an nunit test class repro-ing the issue, but basically, to cut it down to the bare bones
AnyConcreteTypeNotAlreadyRegisteredSource
is used, it throws the error. I would expect this to not be a problem - I mean, it's already explicitly registered, surely it should be excluded from the registration source!AnyConcreteTypeNotAlreadyRegisteredSource
is used, it throws the error.I can exclude the types that aren't working, but it'd be nicer not to have to. Bug? Or am I missing something?
Thanks much
The text was updated successfully, but these errors were encountered: