wrap dangerous client code reflection in try-catch