better error handling in the case of weird non-app being mounted.
Allow mounting an application in a context. This breaks a few
tests involving resolve_model which now become more dependent on
custom attributes in request; need to figure out what to do with that.