FOGE-1739: Handling exceptions gracefully