Database routers need error checking on load
|Reported by:||dhageman||Owned by:||nobody|
|Component:||Database layer (models, ORM)||Version:||master|
|Has patch:||yes||Needs documentation:|
|Needs tests:||Patch needs improvement:|
If you attempt to load a database router which can't be found due to path or attribute issues - you will get an internal server error with a trace back that is long and confusing. It essentially points to the fact that "it can't import name connection" at various spots in the django code base. Attached is a patch which adds error checking which is modeled off the error checking in django.contrib.auth.