add handling for except case