catch and display exceptions