handle exception for async task