-
Notifications
You must be signed in to change notification settings - Fork 29
Resolving MvcRouteHandler #42
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
Comments
Hmm. That's weird. I thought we would only pick constructors we could satisfy. Why is |
Have investigated a bit more. When I However, if I don't configure the root container, and instead create and configure a child container, calling This is a bit of a complicated scenario, but this is as far as I have got so far. |
I'll have a go at creating a replication test to see if this is some issue with |
I have a sneaking suspicion this may be because the root container |
I have an asp.net core 2.0 application.
In
startup
I am callingservices.AddMvc()
;This registers
MvcRouteHandler
as a singleton.MvcRouteHandler
has two constructors. The greediest one takes anIActionContextAccessor
which AFAIK is not ever registered.When I call
app.UseMvc()
- it tries to resolveMvcRouteHandler
. I then see this exception:There is no configuration specified for Microsoft.AspNetCore.Mvc.Infrastructure.IActionContextAccessor
1.) new MvcRouteHandler(Default of IActionInvokerFactory, Default of IActionSelector, Default of DiagnosticSource, Default of ILoggerFactory, Default of IActionContextAccessor)
2.) Microsoft.AspNetCore.Mvc.Internal.MvcRouteHandler
3.) Instance of Microsoft.AspNetCore.Mvc.Internal.MvcRouteHandler
4.) Container.GetInstance(Microsoft.AspNetCore.Mvc.Internal.MvcRouteHandler)
What would be the best way to proceed?
The text was updated successfully, but these errors were encountered: