AttributeRouting icon indicating copy to clipboard operation
AttributeRouting copied to clipboard

Routes seemingly disappear on .NET 4.5.1 with default configuration

Open dotnetchris opened this issue 12 years ago • 0 comments
trafficstars

I don't know how readily reproduciable this is, but on our server that we recently upgraded to .NET 4.5.1 alot of applications broke. The crux of it seems to be related to WebActivator and calls to Assembly.GetCallingAssembly()

It seems that instead of returning the My.Mvc.App assembly, it will instead return WebActivator and unsurprisingly return no routes.

I had to update applications to

routes.MapAttributeRoutes(configuration => configuration.AddRoutesFromAssemblyOf<HomeController>());

dotnetchris avatar Nov 01 '13 14:11 dotnetchris