add try-catch in data_mining