raise exception if element is not found