console handle exception

handle exception