Here are the symptoms I am experiencing:
I have a brand new empty controller in an area:
public class JamController : Controller
{
public JamCo
This is down to a bug in MefContrib.Web.Mvc. This assembly implements it's own ControllerFactory that inherits from DefaultControllerFactory.
The factory overrides GetControllerType, I assume to try and resolve controllers that live in assemblies somewhere other than the default application or it's references. The implementation of GetControllerType first calls into base.GetControllerType to see if Defaultcontroller can resolve it.
If it can't - which is the case for urls that don't exist - it asks MEF for all exports that implement IController. This returns an IEnumerable
It then runs a linq query over the IEnumerable, calling GetType() on the Value property of each Lazy
I don't think this is an easy problem to fix properly as there is no way of getting the Type instance from Lazy