updated error handling when view instantiation fails