Now only excepting AttributeError instead of all errors.