Catch exceptions while initializing